Skip to content

Commit

Permalink
udpate resource files references
Browse files Browse the repository at this point in the history
  • Loading branch information
RHammond2 committed Oct 16, 2024
1 parent efb5b2f commit 5216a1c
Show file tree
Hide file tree
Showing 4 changed files with 11 additions and 10 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,6 @@
warnings.filterwarnings("ignore")
from hopp.tools.resource import *
from hopp.tools.resource.resource_loader import site_details_creator
from hopp import ROOT_DIR

from greenheart.to_organize import hopp_tools_steel
import copy
Expand All @@ -35,6 +34,8 @@
from greenheart.to_organize.hopp_tools_steel import hoppDict
import yaml

ROOT_DIR = Path(__file__).parents[2]

"""
Landbased LCOH analysis
"""
Expand Down Expand Up @@ -88,7 +89,7 @@
desired_lats = np.linspace(23.833504, 49.3556, N_lat)
desired_lons = np.linspace(-129.22923, -65.7146, N_lon)
load_resource_from_file = False
resource_dir = ROOT_DIR / "simulation" / "resource_files"
resource_dir = ROOT_DIR / "resource_files"
sitelist_name = 'filtered_site_details_{}_lats_{}_lons_{}_resourceyear'.format(N_lat, N_lon, resource_year)

if load_resource_from_file:
Expand Down
2 changes: 1 addition & 1 deletion greenheart/tools/eco/utilities.py
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@

from hopp.utilities import load_yaml

from hopp.simulation.technologies.dispatch import plot_tools
from hopp.tools.dispatch import plot_tools

from .finance import adjust_orbit_costs

Expand Down
8 changes: 4 additions & 4 deletions tests/greenheart/test_openmdao.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,17 +8,17 @@

from hopp.simulation import HoppInterface
from hopp.utilities import load_yaml
from hopp import ROOT_DIR

from greenheart.tools.optimization.openmdao import GreenHeartComponent, HOPPComponent, TurbineDistanceComponent, BoundaryDistanceComponent
from greenheart.tools.optimization.gc_run_greenheart import run_greenheart
from greenheart.simulation.greenheart_simulation import GreenHeartSimulationConfig
from hopp import ROOT_DIR

import unittest

solar_resource_file = ROOT_DIR / "simulation" / "resource_files" / "solar" / "35.2018863_-101.945027_psmv3_60_2012.csv"
wind_resource_file = ROOT_DIR / "simulation" / "resource_files" / "wind" / "35.2018863_-101.945027_windtoolkit_2012_60min_80m_100m.srw"
ROOT_DIR = Path(__file__).parents[2]

solar_resource_file = ROOT_DIR / "resource_files" / "solar" / "35.2018863_-101.945027_psmv3_60_2012.csv"
wind_resource_file = ROOT_DIR / "resource_files" / "wind" / "35.2018863_-101.945027_windtoolkit_2012_60min_80m_100m.srw"
floris_input_file = Path(__file__).absolute().parent / "inputs" / "floris_input.yaml"
hopp_config_filename = Path(__file__).absolute().parent / "inputs" / "hopp_config.yaml"
hopp_config_steel_ammonia_filename = Path(__file__).absolute().parent / "input_files" / "plant" / "hopp_config.yaml"
Expand Down
6 changes: 3 additions & 3 deletions tests/greenheart/test_openmdao_mpi.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,10 +13,10 @@
from greenheart.tools.optimization.gc_run_greenheart import run_greenheart
from greenheart.simulation.greenheart_simulation import GreenHeartSimulationConfig

from hopp import ROOT_DIR
ROOT_DIR = Path(__file__).parents[2]

solar_resource_file = ROOT_DIR / "simulation" / "resource_files" / "solar" / "35.2018863_-101.945027_psmv3_60_2012.csv"
wind_resource_file = ROOT_DIR / "simulation" / "resource_files" / "wind" / "35.2018863_-101.945027_windtoolkit_2012_60min_80m_100m.srw"
solar_resource_file = ROOT_DIR / "resource_files" / "solar" / "35.2018863_-101.945027_psmv3_60_2012.csv"
wind_resource_file = ROOT_DIR / "resource_files" / "wind" / "35.2018863_-101.945027_windtoolkit_2012_60min_80m_100m.srw"
floris_input_filename = Path(__file__).absolute().parent / "inputs" / "floris_input.yaml"
hopp_config_filename = Path(__file__).absolute().parent / "input_files" / "plant" / "hopp_config_wind_wave_solar_battery.yaml"
greenheart_config_filename = Path(__file__).absolute().parent / "input_files" / "plant" / "greenheart_config.yaml"
Expand Down

0 comments on commit 5216a1c

Please sign in to comment.