Мини фикс

This commit is contained in:
maksim 2024-12-18 21:29:26 +04:00
parent 578e69555d
commit 78cc7e424d
2 changed files with 3 additions and 3 deletions

View File

@ -32,7 +32,7 @@ class H5Model(Base):
__tablename__ = "h5_models" __tablename__ = "h5_models"
id: Mapped[int] = mapped_column(primary_key=True) id: Mapped[int] = mapped_column(primary_key=True)
user_id: Mapped[int] = mapped_column(ForeignKey("users.id")) user_id: Mapped[int] = mapped_column(ForeignKey("users.id"))
model_path: Mapped[str] path_model: Mapped[str]
created_at: Mapped[datetime] = mapped_column(default=datetime.utcnow) created_at: Mapped[datetime] = mapped_column(default=datetime.utcnow)
user = relationship("User", back_populates="models") user = relationship("User", back_populates="models")

View File

@ -13,11 +13,11 @@ class CSVFileUpload(BaseModel):
# H5ModelCreate: для добавления модели # H5ModelCreate: для добавления модели
class H5ModelCreate(BaseModel): class H5ModelCreate(BaseModel):
model_path: str path_model: str
# ModelStatisticsCreate: для сохранения статистики модели # ModelStatisticsCreate: для сохранения статистики модели
class ModelStatisticsCreate(BaseModel): class ModelStatisticsCreate(BaseModel):
model_id: int id_model: int
accuracy: float accuracy: float
loss: float loss: float
created_at: Optional[datetime] = None created_at: Optional[datetime] = None