Skip to content

Instantly share code, notes, and snippets.

@pwighton
pwighton / FreeSurfer-PetSurfer-by-example.md
Last active September 14, 2025 03:35
Step by step example of running PetSurfer

[Free|Pet]Surfer by Example

Init FreeSurfer env

At the NIH

  • Connect to Biowulf via NoMachine
  • Launch a terminal on Biowulf
  • Run:
@pangyuteng
pangyuteng / README.md
Last active April 17, 2024 08:59
compute suv from pet
** PLEASE NOTE ***
there are many other solutions for computing SUV, see below link for more info.
https://qibawiki.rsna.org/index.php/Standardized_Uptake_Value_(SUV)

This gist contains code to perform the below with python (3.7).

+ download data from TCIA via tcia-rest api. (download.py, tciaclient.py)
@mollymerp
mollymerp / sshfs-gcp-instance-osx.md
Last active August 4, 2025 08:07
How to mount a GCP compute instance filesystem locally using `sshfs` on MacOS

How to mount a GCP compute instance filesystem locally using sshfs

This guide assumes that:

  • you already have an instance set up on GCP that you want to mount locally
  • the GCP CLI (gcloud) is installed on your local machine
  • you have authenticated locally to your google account gcloud auth login
  1. make sure your gcloud config is correct for the instance you're trying to access:
anonymous
anonymous / .bashrc
Created September 27, 2016 19:19
How to change cursor shape, color, and blinkrate of Linux Console
##############
# pretty prompt and font colors
##############
# alter the default colors to make them a bit prettier
echo -en "\e]P0000000" #black
echo -en "\e]P1D75F5F" #darkred
echo -en "\e]P287AF5F" #darkgreen
echo -en "\e]P3D7AF87" #brown
echo -en "\e]P48787AF" #darkblue
@fabianp
fabianp / partial_corr.py
Last active March 21, 2024 09:00
Partial Correlation in Python (clone of Matlab's partialcorr)
"""
Partial Correlation in Python (clone of Matlab's partialcorr)
This uses the linear regression approach to compute the partial
correlation (might be slow for a huge number of variables). The
algorithm is detailed here:
http://en.wikipedia.org/wiki/Partial_correlation#Using_linear_regression
Taking X and Y two variables of interest and Z the matrix with all the variable minus {X, Y},
"""
----------------------------------
jg_MUSC_connectome_tractography.py
----------------------------------
Modified version of MUSC connectome (probabilistic) tractography pipeline
(original code is at bottom of file, plus links to website)
Modifications: