Description Usage Arguments Value Examples
Make a patches list for a population of images
1 2 3 4 5 6 7 8 9 10 11 |
t1 |
a character vector of filenames for T1 images |
flair |
a character vector of filenames for FLAIR images |
mask |
a character vector of filenames for mask images |
t2 |
a character vector of filenames for T2 images |
patchsize |
Vector of length 2 (or more) |
verbose |
print diagnostic messages |
outfile |
Output file to write arrays, an |
write_file |
Should an output file be written |
... |
Additional arguments to pass to |
A list of named arrays
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 | user = Sys.getenv("USER")
if (user %in% c("johnmuschelli", "travis") &
Sys.info()["sysname"] == "Darwin"){
reticulate::use_python(paste0(
"/Library/Frameworks/Python.framework/Versions/3.5/bin/python3"))
} else {
python = system("which python", intern = TRUE)
print(python)
reticulate::use_python(python)
}
data_dir = "/Volumes/DATA_LOCAL/Projects/ms_lesion_challenge/atlases/none"
if (dir.exists(data_dir)) {
i = 1:5
t1 <- paste0("atlas", i, "_T1.nii.gz")
flair = paste0("atlas", i, "_FL.nii.gz")
t2 = NULL
mask = paste0("atlas", i, "_mask.nii.gz")
t1 = file.path(data_dir, t1)
flair = file.path(data_dir, flair)
mask = file.path(data_dir, mask)
verbose = TRUE
patchsize = c(35, 35)
outfile = NULL
write_file = TRUE
}
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.