We have a file store set up for analysis files, and we've realized that we need to create a subdirectory structure within in. The dj.config settings are below, and the schema definition is
@schema
class AnalysisNwbfile(dj.Manual):
definition = """
# Table for holding the NWB files that contain results of analysis, such as spike sorting.
analysis_file_name: varchar(255) # name of the file
---
-> Nwbfile # name of the parent NWB file. Used for naming and metadata copy
analysis_file_abs_path: filepath@analysis # the full path to the file
analysis_file_description = "": varchar(2000) # an optional description of this analysis
analysis_parameters = NULL: blob # additional relevant parmeters. Currently used only for analyses
# that span multiple NWB files
INDEX (analysis_file_abs_path)
"""
dj.config:
dj.config['stores'] = {
'raw': {
'protocol': 'file',
'location': str(raw_dir),
'stage': str(raw_dir)
},
'analysis': {
'protocol': 'file',
'location': str(analysis_dir),
'stage': str(analysis_dir)
}
}
We currently have ~355k files in analysis_dir, and we'd like to move them to subdirectories to prevent filesystem problems. Is there any way to do that?