diff --git a/ingestion_tools/dataset_configs/template.yaml b/ingestion_tools/dataset_configs/template.yaml index c41730f13..da9d44d98 100644 --- a/ingestion_tools/dataset_configs/template.yaml +++ b/ingestion_tools/dataset_configs/template.yaml @@ -117,16 +117,20 @@ tomograms: standardization_config: destination_prefix: '99999' source_prefix: path/to/source + run_glob: frames/* + run_regex: /TS_\d\d$ + run_name_regex: (.*) frames_glob: frames/{run_name}_*.tif + frames_name_regex: (.*) gain_glob: frames/CountRef.dm4 rawtlt_files: - metadata/{run_name}.rawtlt - metadata/{run_name}.xf - metadata/mdocs_modified/{run_name}.mdoc tiltseries_glob: metadata/{run_name}.st + ts_name_regex: (.*)\.rec tomo_format: mrc tomo_glob: tomograms/*.rec + tomo_regex: (.*)\.mrc tomo_voxel_size: '13.48' - run_glob: frames/* - run_regex: /TS_\d\d$ - run_name_regex: (.*) + tomo_key_photo_glob: .*\.jpg diff --git a/ingestion_tools/scripts/common/config.py b/ingestion_tools/scripts/common/config.py index 29e2299f1..e3f2f863e 100644 --- a/ingestion_tools/scripts/common/config.py +++ b/ingestion_tools/scripts/common/config.py @@ -36,22 +36,22 @@ class DataImportConfig: run_regex: re.Pattern[str] tomo_glob: str tomo_format: str - tomo_regex: re.Pattern[str] | None - tomo_key_photo_glob: str | None + tomo_regex: re.Pattern[str] | None = None + tomo_key_photo_glob: str | None = None tomo_voxel_size: str - ts_name_regex: re.Pattern[str] | None + ts_name_regex: re.Pattern[str] | None = None run_name_regex: re.Pattern[str] - frames_name_regex: re.Pattern[str] + frames_name_regex: re.Pattern[str] | None = None frames_glob: str - tiltseries_glob: str | None - run_to_tomo_map_file: str | None - run_to_tomo_map: dict[str, str] | None - run_to_frame_map_csv: str | None - run_to_frame_map: dict[str, str] | None - run_to_ts_map_csv: str | None - run_to_ts_map: dict[str, str] | None + tiltseries_glob: str | None = None + run_to_tomo_map_file: str | None = None + run_to_tomo_map: dict[str, str] | None = None + run_to_frame_map_csv: str | None = None + run_to_frame_map: dict[str, str] | None = None + run_to_ts_map_csv: str | None = None + run_to_ts_map: dict[str, str] | None = None gain_glob: str - rawtlt_files: list[str] | None + rawtlt_files: list[str] | None = None # metadata templates dataset_template: dict[str, Any] run_template: dict[str, Any] @@ -60,9 +60,9 @@ class DataImportConfig: annotation_template: dict[str, Any] output_prefix: str input_prefix: str - overrides_by_run: list[RunOverride] | None + overrides_by_run: list[RunOverride] | None = None run_data_map: dict[str, Any] - run_data_map_file: str | None + run_data_map_file: str | None = None def __init__(self, fs: FileSystemApi, config_path: str, output_prefix: str, input_bucket: str): self.output_prefix = output_prefix