-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* updated to work with cdr * Think this is it * updated * update * update * refactor * schema * updated --------- Co-authored-by: スコット <[email protected]>
- Loading branch information
1 parent
89d7903
commit 1e2a264
Showing
4 changed files
with
136 additions
and
147 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,43 @@ | ||
from typing import List, Union | ||
|
||
from pydantic import BaseModel, Field | ||
|
||
from cdr_schemas.prospectivity_input import ( | ||
CreateCriticalMineralAssessment, | ||
CreateDataSource, | ||
TranformMethods, | ||
) | ||
from cdr_schemas.prospectivity_models import NeuralNetUserOptions, SOMTrainConfig | ||
|
||
|
||
class CriticalMineralAssessment(CreateCriticalMineralAssessment): | ||
cma_id: str = Field(description="ID of the cma") | ||
download_url: str = Field(description="url to view template raster") | ||
|
||
|
||
class DataSource(CreateDataSource): | ||
data_source_id: str = Field(default="") | ||
download_url: str | ||
|
||
|
||
class CreateProcessDataLayer(BaseModel): | ||
cma: CriticalMineralAssessment = Field( | ||
description="CMA with all information needed for processing" | ||
) | ||
data_source: DataSource = Field(description="Data source to create this layer") | ||
title: str = Field(description="Title to use for processed layer") | ||
transform_methods: TranformMethods = Field( | ||
default="", description="Transformation method used" | ||
) | ||
|
||
|
||
class ProspectModelMetaData(BaseModel): | ||
""" | ||
# CDR to TA3: EVENT | ||
provides a model run id, cma | ||
""" | ||
|
||
model_run_id: str = Field(description="CDR id of the model run") | ||
cma: CriticalMineralAssessment = Field(description="CMA info") | ||
train_config: Union[SOMTrainConfig, NeuralNetUserOptions] | ||
evidence_layers: List[CreateProcessDataLayer] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters