Skip to content

Commit

Permalink
test: use yaml model in requested pressure test
Browse files Browse the repository at this point in the history
  • Loading branch information
jsolaas committed Oct 31, 2024
1 parent c4f238a commit 8c855e1
Show file tree
Hide file tree
Showing 14 changed files with 370 additions and 1,520 deletions.
1 change: 1 addition & 0 deletions src/libecalc/fixtures/__init__.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
from .case_types import DTOCase, YamlCase
from .cases.all_energy_usage_models import * # noqa: F403
from .cases.compressor_systems_and_compressor_train_temporal import compressor_systems_and_compressor_train_temporal
from .cases.consumer_system_v2 import (
consumer_system_v2_yaml,
)
Expand Down
46 changes: 0 additions & 46 deletions src/libecalc/fixtures/cases/all_energy_usage_models/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,52 +5,6 @@
from libecalc.fixtures import YamlCase
from libecalc.fixtures.case_utils import YamlCaseLoader

from .all_models_dto import (
compressor,
compressor_system,
compressor_system_variable_speed_compressor_trains,
compressor_system_variable_speed_compressor_trains_multiple_suction_discharge_pressures,
compressor_systems_and_compressor_train_temporal_dto,
deh,
flare,
generic_from_design_point_compressor_train_consumer,
genset_sampled,
late_start_consumer,
late_start_consumer_evolving_type,
methane_venting,
pump_system_el_consumer,
salt_water_injection_tabular,
simplified_compressor_system,
simplified_compressor_train_predefined_variable_speed_charts_with_gerg_fluid,
simplified_variable_speed_compressor_train_known_stages_consumer,
simplified_variable_speed_compressor_train_known_stages_consumer_temporal_model,
simplified_variable_speed_compressor_train_unknown_stages_consumer,
single_speed_compressor_train_asv_pressure_control,
single_speed_compressor_train_downstream_choke_pressure_control,
single_speed_compressor_train_downstream_choke_pressure_control_maximum_discharge_pressure,
single_speed_compressor_train_upstream_choke_pressure_control,
tabulated,
turbine_driven_compressor_train,
variable_speed_compressor_train_multiple_input_streams_and_interstage_pressure,
variable_speed_compressor_train_predefined_charts,
water_injection_single_speed,
water_injection_variable_speed,
)
from .conftest import (
all_energy_usage_models_variables,
compressor_sampled_1d,
compressor_train_variable_speed_user_defined_fluid_and_compressor_chart_and_turbine2,
compressor_with_turbine,
methane_values,
regularity,
simplified_variable_speed_compressor_train_known_stages,
simplified_variable_speed_compressor_train_with_gerg_fluid2,
single_speed_pump,
turbine_dto,
user_defined_single_speed_compressor_chart_dto,
variable_speed_pump,
)

"""
Test project for All Energy Usage Models
Expand Down
1,159 changes: 0 additions & 1,159 deletions src/libecalc/fixtures/cases/all_energy_usage_models/all_models_dto.py

This file was deleted.

288 changes: 0 additions & 288 deletions src/libecalc/fixtures/cases/all_energy_usage_models/conftest.py

This file was deleted.

Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
from pathlib import Path

import pytest

from libecalc.fixtures import YamlCase, YamlCaseLoader


@pytest.fixture
def compressor_systems_and_compressor_train_temporal() -> YamlCase:
return YamlCaseLoader.load(
case_path=Path(__file__).parent / "data",
main_file="root_model.yaml",
resource_names=[
"predefined_compressor_chart_curves.csv",
"genset.csv",
"compressor_sampled_1d.csv",
"base_profile.csv",
"flare.csv",
],
)
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
DATE,OIL_PROD,WATER_PROD,GAS_PROD,WATER_INJ,GAS_LIFT,REGULARITY,POWERLOSS_CONSTANT
01.01.2017,5016,23410,6070485,31977,60704.85,1,0.00
01.01.2018,4092,24920,4744704,28750,60704.85,1,0.00
01.01.2019,3483,25807,5334699,29128,60704.85,1,0.024
01.01.2020,3051,23196,5676338,25270,60704.85,0,0.04
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
RATE,FUEL,POWER
0,0,0
1000000,10000,1.0
2000000,11000,2.0
3000000,12000,3.0
4000000,13000,4.0

Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
DATE, FLARE_RATE, METHANE_RATE
01.01.2017,10000.0, 3.0
01.01.2018,10000.0, 3.0
01.01.2019,14000.0, 6.0
01.01.2020,14000.0, 6.0
Loading

0 comments on commit 8c855e1

Please sign in to comment.