Skip to content

Commit

Permalink
Merge pull request #198 from NCAR/main
Browse files Browse the repository at this point in the history
Version 2.2.2
  • Loading branch information
K20shores committed Aug 27, 2024
2 parents 8dc210d + 72ae859 commit 1b0071e
Show file tree
Hide file tree
Showing 5 changed files with 12 additions and 10 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ MusicBox: A MUSICA model for boxes and columns.

[![License](https://img.shields.io/github/license/NCAR/music-box.svg)](https://github.com/NCAR/music-box/blob/main/LICENSE)
[![CI Status](https://github.com/NCAR/music-box/actions/workflows/CI_Tests.yml/badge.svg)](https://github.com/NCAR/music-box/actions/workflows/CI_Tests.yml)
[![PyPI version](https://badge.fury.io/py/acom_music_box.svg)](https://pypi.org/p/acom_music_box)
[![PyPI version](https://badge.fury.io/py/acom-music-box.svg)](https://badge.fury.io/py/acom-music-box)

Copyright (C) 2020 National Center for Atmospheric Research

Expand Down
2 changes: 1 addition & 1 deletion src/acom_music_box/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
This package contains modules for handling various aspects of a music box,
including species, products, reactants, reactions, and more.
"""
__version__ = "2.2.1"
__version__ = "2.2.2"

from .utils import convert_time, convert_pressure, convert_temperature, convert_concentration
from .species import Species
Expand Down
10 changes: 5 additions & 5 deletions src/acom_music_box/evolving_conditions.py
Original file line number Diff line number Diff line change
Expand Up @@ -129,11 +129,11 @@ def from_config_JSON(
if 'evolving conditions' in config_JSON:
if len(config_JSON['evolving conditions'].keys()) > 0:
# Construct the path to the evolving conditions file
evolving_conditions_path = (
os.path.dirname(path_to_json) +
"/" +
list(
config_JSON['evolving conditions'].keys())[0])

evolving_conditions_path = os.path.join(
os.path.dirname(path_to_json),
list(config_JSON['evolving conditions'].keys())[0])

evolving_conditions = EvolvingConditions.read_conditions_from_file(
evolving_conditions_path, species_list, reaction_list)

Expand Down
3 changes: 2 additions & 1 deletion src/acom_music_box/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -76,6 +76,7 @@ def main():

# create and load a MusicBox object
myBox = MusicBox()
logging.info("configuration file = {}".format(musicBoxConfigFile))
myBox.readConditionsFromJson(musicBoxConfigFile)
logger.info("myBox = {}".format(myBox))

Expand All @@ -87,7 +88,7 @@ def main():
myBox.create_solver(campConfig)
logger.info("myBox.solver = {}".format(myBox.solver))
mySolution = myBox.solve(os.path.join(musicBoxOutputDir, "mySolution.csv"))
logger.info("mySolution = {}".format(mySolution))
# logger.info("mySolution = {}".format(mySolution))

logger.info("End time: {}".format(datetime.datetime.now()))
sys.exit(0)
Expand Down
5 changes: 3 additions & 2 deletions src/acom_music_box/reaction_list.py
Original file line number Diff line number Diff line change
Expand Up @@ -71,8 +71,9 @@ def from_config_JSON(cls, path_to_json, config_JSON, species_list):
list_name = None

# gets config file path
config_file_path = os.path.dirname(
path_to_json) + "/" + config_JSON['model components'][0]['configuration file']
config_file_path = os.path.join(
os.path.dirname(path_to_json),
config_JSON['model components'][0]['configuration file'])

# opnens config path to read reaction file
with open(config_file_path, 'r') as json_file:
Expand Down

0 comments on commit 1b0071e

Please sign in to comment.