Skip to content

Commit

Permalink
New data models (#286)
Browse files Browse the repository at this point in the history
* refactor: first draft containers

* refactor: finish containers first draft

* refactor: starting on views

* more containers

* backend containers finished

* more views

* finished Scenario view

* refactor: start on water value based

* refactor: shell for water value based

* shopResult view finished

* restructure view files

* refactor: one new space

* add view version variable

* refactor: update containers to one space

* refactor: moved all old views

* refactor and finish function inputs for shop based process

* function inputs and outputs for shop process finished

* refactor: to powerops_models space

* refactor: cleanup power assets

* refactor: cleanup naming of all files

* refactor: replace all versions

* refactor: setup all data models

* refactor: cleanup variables

* refactor: Fix bug in views

* refactor: update validation code

* refactor; scenario interface

* refactor: Partial post processing input

* refactor: added missing views

* refactor: fix types

* refactor: schema validation passing

* refactor: fix manual inspection

* refactor: fix nullable containers

* refactor: fix bugs in containers

* refactor: fix bug in bid document AFRR

* renamed spaces and finished dayahead bidconfig

* shopBased finished

* watervalue process finish

* change names of some views in the data models

* [POWEROPS-2102] Test read write instances (#294)

* build: pygen to 99

* build: pygen 99.1

* refactor: write read instance test

* refactor: pygen to 99.2

* schema validate works

* added data filters

* fix filter and init

* change back to batch resource apply

* bid configuration done

* change back to fronend contract for priceArea and use string in bid confic instead of direct relation

* review done

* add all views to powerops datamodel

* add frans changes

* add name from price area container to view

* last deployed changes + change hardcoded spacename for previously shared space

* Made some changes to Price area. Last deploy

* redeployed with price area view now using asset container name

* add validation on source if direct_relation and make generic bidmethod view

* add new view and deploy

* refactor: restore models correctly

* refactor: fix spaces

* fix: folders

* refactor; readjusting

* refactor: removed method and price area form BidConfig interface

* fix: data model names

* build: lock

---------

Co-authored-by: Juliamg <[email protected]>
  • Loading branch information
doctrino and Juliamg authored Feb 8, 2024
1 parent 5884f4a commit 267276d
Show file tree
Hide file tree
Showing 100 changed files with 5,788 additions and 78 deletions.
7 changes: 6 additions & 1 deletion cognite/powerops/config.dev.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,15 @@ environment:
project: power-ops-staging
type: dev
selected_modules_and_packages:
- power_model_v0
- power_model_v1

modules:
custom_modules:
power_model_v1:
powerops_type_space: 'sp_powerops_types'
powerops_instance_space: 'sp_powerops_instance'
powerops_models: 'sp_powerops_models'
version: '1'
power_model_v0:
# variables used for substitution in other files in this directory
afrr_model_space: 'power-ops-afrr-bid'
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,241 @@
externalId: all_PowerOps
space: '{{powerops_models}}'
version: '{{version}}'
name: all_PowerOps
views:
- externalId: SHOPResult
space: '{{powerops_models}}'
type: view
version: '{{version}}'
- externalId: BidRow
space: '{{powerops_models}}'
type: view
version: '{{version}}'
- externalId: PriceScenario
space: '{{powerops_models}}'
type: view
version: '{{version}}'
- externalId: MarketConfiguration
space: '{{powerops_models}}'
type: view
version: '{{version}}'
- externalId: BidCalculationTask
space: '{{powerops_models}}'
type: view
version: '{{version}}'
- externalId: Alert
space: '{{powerops_models}}'
type: view
version: '{{version}}'
- externalId: ModelTemplate
space: '{{powerops_models}}'
type: view
version: '{{version}}'
- externalId: Mapping
space: '{{powerops_models}}'
type: view
version: '{{version}}'
- externalId: BidConfigurationShop
space: '{{powerops_models}}'
type: view
version: '{{version}}'
- externalId: BidConfiguration
space: '{{powerops_models}}'
type: view
version: '{{version}}'
- externalId: BidConfigurationAFRR
space: '{{powerops_models}}'
type: view
version: '{{version}}'
- externalId: BidConfigurationWater
space: '{{powerops_models}}'
type: view
version: '{{version}}'
- externalId: SHOPTriggerInput
space: '{{powerops_models}}'
type: view
version: '{{version}}'
- externalId: WaterPartialBidCalculationInput
space: '{{powerops_models}}'
type: view
version: '{{version}}'
- externalId: PreprocessorInput
space: '{{powerops_models}}'
type: view
version: '{{version}}'
- externalId: FunctionInput
space: '{{powerops_models}}'
type: view
version: '{{version}}'
- externalId: TotalBidMatrixCalculationInput
space: '{{powerops_models}}'
type: view
version: '{{version}}'
- externalId: TaskDispatcherShopInput
space: '{{powerops_models}}'
type: view
version: '{{version}}'
- externalId: TaskDispatcherWaterInput
space: '{{powerops_models}}'
type: view
version: '{{version}}'
- externalId: PartialPostProcessingInput
space: '{{powerops_models}}'
type: view
version: '{{version}}'
- externalId: ShopPartialBidCalculationInput
space: '{{powerops_models}}'
type: view
version: '{{version}}'
- externalId: ScenarioRaw
space: '{{powerops_models}}'
type: view
version: '{{version}}'
- externalId: ScenarioBase
space: '{{powerops_models}}'
type: view
version: '{{version}}'
- externalId: Scenario
space: '{{powerops_models}}'
type: view
version: '{{version}}'
- externalId: PreprocessorOutput
space: '{{powerops_models}}'
type: view
version: '{{version}}'
- externalId: WaterPartialBidCalculationOutput
space: '{{powerops_models}}'
type: view
version: '{{version}}'
- externalId: SHOPTriggerOutput
space: '{{powerops_models}}'
type: view
version: '{{version}}'
- externalId: PartialPostProcessingOutput
space: '{{powerops_models}}'
type: view
version: '{{version}}'
- externalId: ShopPartialBidCalculationOutput
space: '{{powerops_models}}'
type: view
version: '{{version}}'
- externalId: FunctionOutput
space: '{{powerops_models}}'
type: view
version: '{{version}}'
- externalId: TaskDispatcherWaterOutput
space: '{{powerops_models}}'
type: view
version: '{{version}}'
- externalId: TotalBidMatrixCalculationOutput
space: '{{powerops_models}}'
type: view
version: '{{version}}'
- externalId: TaskDispatcherShopOutput
space: '{{powerops_models}}'
type: view
version: '{{version}}'
- externalId: BidDocument
space: '{{powerops_models}}'
type: view
version: '{{version}}'
- externalId: BidDocumentDayAhead
space: '{{powerops_models}}'
type: view
version: '{{version}}'
- externalId: BidDocumentAFRR
space: '{{powerops_models}}'
type: view
version: '{{version}}'
- externalId: PowerAsset
space: '{{powerops_models}}'
type: view
version: '{{version}}'
- externalId: Generator
space: '{{powerops_models}}'
type: view
version: '{{version}}'
- externalId: PriceAreaDayAhead
space: '{{powerops_models}}'
type: view
version: '{{version}}'
- externalId: WatercourseShop
space: '{{powerops_models}}'
type: view
version: '{{version}}'
- externalId: TurbineEfficiencyCurve
space: '{{powerops_models}}'
type: view
version: '{{version}}'
- externalId: Reservoir
space: '{{powerops_models}}'
type: view
version: '{{version}}'
- externalId: Plant
space: '{{powerops_models}}'
type: view
version: '{{version}}'
- externalId: PlantShop
space: '{{powerops_models}}'
type: view
version: '{{version}}'
- externalId: Watercourse
space: '{{powerops_models}}'
type: view
version: '{{version}}'
- externalId: PriceArea
space: '{{powerops_models}}'
type: view
version: '{{version}}'
- externalId: GeneratorEfficiencyCurve
space: '{{powerops_models}}'
type: view
version: '{{version}}'
- externalId: PriceAreaAFRR
space: '{{powerops_models}}'
type: view
version: '{{version}}'
- externalId: BidMethod
space: '{{powerops_models}}'
type: view
version: '{{version}}'
- externalId: BidMethodWaterValue
space: '{{powerops_models}}'
type: view
version: '{{version}}'
- externalId: BidMethodSHOPMultiScenario
space: '{{powerops_models}}'
type: view
version: '{{version}}'
- externalId: BidMethodCustom
space: '{{powerops_models}}'
type: view
version: '{{version}}'
- externalId: BidMethodDayAhead
space: '{{powerops_models}}'
type: view
version: '{{version}}'
- externalId: BidMethodAFRR
space: '{{powerops_models}}'
type: view
version: '{{version}}'
- externalId: BidMatrixRaw
space: '{{powerops_models}}'
type: view
version: '{{version}}'
- externalId: BidMatrix
space: '{{powerops_models}}'
type: view
version: '{{version}}'
- externalId: CustomBidMatrix
space: '{{powerops_models}}'
type: view
version: '{{version}}'
- externalId: MultiScenarioMatrix
space: '{{powerops_models}}'
type: view
version: '{{version}}'
- externalId: BasicBidMatrix
space: '{{powerops_models}}'
type: view
version: '{{version}}'
Original file line number Diff line number Diff line change
@@ -0,0 +1,82 @@
externalId: compute_SHOPBasedDayAhead
space: '{{powerops_models}}'
version: '1'
name: SHOPBasedDayAheadBidProcess
description: 'The process of going from BidConfig to a PartialBidMatrix'
views:
- externalId: TaskDispatcherShopInput
space: '{{powerops_models}}'
type: view
version: '{{version}}'
- externalId: TaskDispatcherShopOutput
space: '{{powerops_models}}'
type: view
version: '{{version}}'
- externalId: PreprocessorInput
space: '{{powerops_models}}'
type: view
version: '{{version}}'
- externalId: PreprocessorOutput
space: '{{powerops_models}}'
type: view
version: '{{version}}'
- externalId: SHOPTriggerInput
space: '{{powerops_models}}'
type: view
version: '{{version}}'
- externalId: SHOPTriggerOutput
space: '{{powerops_models}}'
type: view
version: '{{version}}'
- externalId: ShopPartialBidCalculationInput
space: '{{powerops_models}}'
type: view
version: '{{version}}'
- externalId: ShopPartialBidCalculationOutput
space: '{{powerops_models}}'
type: view
version: '{{version}}'
- externalId: BidMatrixRaw
space: '{{powerops_models}}'
type: view
version: '{{version}}'
- externalId: BidMethodDayAhead
space: '{{powerops_models}}'
type: view
version: '{{version}}'
- externalId: ScenarioRaw
space: '{{powerops_models}}'
type: view
version: '{{version}}'
- externalId: Scenario
space: '{{powerops_models}}'
type: view
version: '{{version}}'
- externalId: Mapping
space: '{{powerops_models}}'
type: view
version: '{{version}}'
- externalId: ModelTemplate
space: '{{powerops_models}}'
type: view
version: '{{version}}'
- externalId: SHOPResult
space: '{{powerops_models}}'
type: view
version: '{{version}}'
- externalId: Alert
space: '{{powerops_models}}'
type: view
version: '{{version}}'
- externalId: PlantShop
space: '{{powerops_models}}'
type: view
version: '{{version}}'
- externalId: WatercourseShop
space: '{{powerops_models}}'
type: view
version: '{{version}}'
- externalId: BidConfigurationShop
space: '{{powerops_models}}'
type: view
version: '{{version}}'
Loading

0 comments on commit 267276d

Please sign in to comment.