|
4 | 4 | """ |
5 | 5 |
|
6 | 6 | from datetime import datetime |
7 | | -from typing import List, Optional |
| 7 | +from typing import TYPE_CHECKING, List, Optional |
8 | 8 |
|
9 | 9 | import sqlalchemy |
10 | 10 | from sqlmodel import Field, Relationship, SQLModel, create_engine |
11 | 11 |
|
12 | | -from murfey.util.processing_db import ( |
13 | | - CTF, |
14 | | - MotionCorrection, |
15 | | - ParticleClassificationGroup, |
16 | | - ParticlePicker, |
17 | | - RelativeIceThickness, |
18 | | - TiltImageAlignment, |
19 | | - Tomogram, |
20 | | -) |
| 12 | +if TYPE_CHECKING: |
| 13 | + from murfey.util.processing_db import ( |
| 14 | + CTF, |
| 15 | + MotionCorrection, |
| 16 | + ParticleClassificationGroup, |
| 17 | + ParticlePicker, |
| 18 | + RelativeIceThickness, |
| 19 | + TiltImageAlignment, |
| 20 | + Tomogram, |
| 21 | + ) |
21 | 22 |
|
22 | 23 | """ |
23 | 24 | GENERAL |
@@ -712,7 +713,7 @@ class FoilHole(SQLModel, table=True): # type: ignore |
712 | 713 | class SearchMap(SQLModel, table=True): # type: ignore |
713 | 714 | id: Optional[int] = Field(primary_key=True, default=None) |
714 | 715 | session_id: int = Field(foreign_key="session.id") |
715 | | - atlasId: Optional[int] = Field(foreign_key="data_collection_group.id") |
| 716 | + atlas_id: Optional[int] = Field(foreign_key="data_collection_group.id") |
716 | 717 | name: str |
717 | 718 | tag: str |
718 | 719 | x_location: Optional[float] = None |
@@ -761,8 +762,6 @@ class Movie(SQLModel, table=True): # type: ignore |
761 | 762 | image_number: int |
762 | 763 | tag: str |
763 | 764 | preprocessed: bool = False |
764 | | - createdTimeStamp: Optional[datetime] = None |
765 | | - movie_full_path: Optional[str] = None |
766 | 765 | murfey_ledger: Optional[MurfeyLedger] = Relationship(back_populates="movies") |
767 | 766 | foil_hole: Optional[FoilHole] = Relationship(back_populates="movies") |
768 | 767 | data_collection: Optional["DataCollection"] = Relationship(back_populates="movies") |
|
0 commit comments