-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
refactored code to load filepaths from loadFilePaths
- Loading branch information
1 parent
d3b09d8
commit afacafe
Showing
20 changed files
with
235 additions
and
373 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,83 @@ | ||
# -*- coding: utf-8 -*- | ||
""" | ||
Created on Thu Oct 8 12:15:29 2020 | ||
@author: fubar | ||
""" | ||
|
||
import os, os.path | ||
|
||
from globalVariables import debug, raw_dir, proc_dir, seq_file, samplename | ||
|
||
from globalVariables import mpl_stylesheet | ||
|
||
|
||
#### global read only ####### | ||
|
||
imgs_folder = r'Images' | ||
fits_folder = r'Fits' | ||
restored_folder = r'Restored' | ||
figs_folder = r'Figures' | ||
vel_folder = r'Velocity' | ||
|
||
space_filename = 'space.npy' | ||
controls_filename = 'controls.npy' | ||
|
||
######### Post Processing folders and files ################### | ||
parent_dir_abs = os.path.abspath(os.path.join(os.pardir, os.pardir)) | ||
|
||
if debug: print(f'parent_dir_abs: {parent_dir_abs}') | ||
|
||
raw_dir_abs = os.path.abspath(os.path.join(parent_dir_abs, raw_dir)) | ||
if not os.path.isdir(raw_dir_abs): os.mkdir(raw_dir_abs) | ||
|
||
proc_dir_abs = os.path.abspath(os.path.join(parent_dir_abs, proc_dir)) | ||
if not os.path.isdir(proc_dir_abs): os.mkdir(proc_dir_abs) | ||
|
||
fits_dir_abs = os.path.abspath(os.path.join(proc_dir_abs,fits_folder)) | ||
if not os.path.isdir(fits_dir_abs): os.mkdir(fits_dir_abs) | ||
|
||
fits_root = os.path.abspath(os.path.join(fits_dir_abs,samplename)) | ||
if not os.path.isdir(fits_root): os.mkdir(fits_root) | ||
|
||
space_filepath = os.path.abspath(os.path.join(fits_root,space_filename)) | ||
|
||
controls_filepath = os.path.abspath(os.path.join(fits_root, controls_filename)) | ||
|
||
######images folders######### | ||
|
||
# image fits folder root | ||
img_dir_abs = os.path.abspath(os.path.join(proc_dir_abs, imgs_folder)) | ||
if not os.path.isdir(img_dir_abs): os.mkdir(img_dir_abs) | ||
|
||
img_root = os.path.abspath(os.path.join(img_dir_abs,samplename)) | ||
if not os.path.isdir(img_root): os.mkdir(img_root) | ||
|
||
# restored image fits folder root | ||
restored_dir_abs = os.path.abspath(os.path.join(proc_dir_abs, restored_folder)) | ||
if not os.path.isdir(restored_dir_abs): os.mkdir(restored_dir_abs) | ||
|
||
restored_root = os.path.abspath(os.path.join(restored_dir_abs,samplename)) | ||
if not os.path.isdir(restored_root): os.mkdir(restored_root) | ||
|
||
|
||
######### figures folder ######## | ||
|
||
figs_dir_abs = os.path.abspath(os.path.join(proc_dir_abs, figs_folder)) | ||
if not os.path.isdir(figs_dir_abs): os.mkdir(figs_dir_abs) | ||
|
||
figs_root = os.path.abspath(os.path.join(figs_dir_abs,samplename)) | ||
if not os.path.isdir(figs_root): os.mkdir(figs_root) | ||
|
||
######## velocity folder ####### | ||
|
||
vel_dir_abs = os.path.abspath(os.path.join(proc_dir_abs, vel_folder)) | ||
if not os.path.isdir(vel_dir_abs): os.mkdir(vel_dir_abs) | ||
|
||
vel_root = os.path.abspath(os.path.join(vel_dir_abs,samplename)) | ||
if not os.path.isdir(vel_root): os.mkdir(vel_root) | ||
|
||
######## matplotlib stylesheet file ####### | ||
|
||
mpl_stylesheet_file = os.path.abspath(os.path.join(parent_dir_abs, mpl_stylesheet)) | ||
|
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.