Skip to content

Commit ef33445

Browse files
committed
Pydantic doesn't like things starting model_
1 parent d940ee3 commit ef33445

File tree

2 files changed

+5
-3
lines changed

2 files changed

+5
-3
lines changed

src/murfey/server/api/spa.py

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,15 +20,17 @@ def _cryolo_model_path(visit: str, instrument_name: str) -> Path:
2020
machine_config = get_machine_config(instrument_name=instrument_name)[
2121
instrument_name
2222
]
23-
if machine_config.model_search_directory:
23+
if machine_config.picking_model_search_directory:
2424
visit_directory = (
2525
machine_config.rsync_basepath
2626
/ (machine_config.rsync_module or "data")
2727
/ str(datetime.now().year)
2828
/ visit
2929
)
3030
possible_models = list(
31-
(visit_directory / machine_config.model_search_directory).glob("*.h5")
31+
(visit_directory / machine_config.picking_model_search_directory).glob(
32+
"*.h5"
33+
)
3234
)
3335
if possible_models:
3436
return sorted(possible_models, key=lambda x: x.stat().st_ctime)[-1]

src/murfey/util/config.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,7 @@ class MachineConfig(BaseModel):
5858
upstream_data_download_directory: Optional[Path] = None # Set by microscope config
5959
upstream_data_tiff_locations: List[str] = ["processed"] # Location of CLEM TIFFs
6060

61-
model_search_directory: str = "processing"
61+
picking_model_search_directory: str = "processing"
6262
initial_model_search_directory: str = "processing/initial_model"
6363

6464
failure_queue: str = ""

0 commit comments

Comments
 (0)