Skip to content

Commit

Permalink
Merge pull request #18 from NOAA-GFDL/restructure
Browse files Browse the repository at this point in the history
Fix small bug
  • Loading branch information
ceblanton authored Dec 12, 2024
2 parents 4e555ab + c9ebb12 commit f8dcd27
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
1 change: 0 additions & 1 deletion core/analysis_scripts/analysis_scripts/plugins.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,6 @@ def __enter__(self):
"""Adjusts the sys path so the modules and packages can be imported."""
if self.path not in sys.path:
sys.path.insert(0, self.path)
print(sys.path)
return self

def __exit__(self, exception_type, exception_value, traceback):
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -75,16 +75,16 @@ def requires(self):
},
})

def run_analysis(self, catalog, png_dir, reference_catalog=None, config={}):
def run_analysis(self, catalog, png_dir, config=None, reference_catalog=None):
"""Runs the analysis and generates all plots and associated datasets.
Args:
catalog: Path to a catalog.
png_dir: Path to the directory where the figures will be made.
reference_catalog: Path to a catalog of reference data.
config: Dictonary of catalog metadata. Will overwrite the
data defined in the Metadata helper class if they both
contain the same keys.
reference_catalog: Path to a catalog of reference data.
Returns:
A list of paths to the figures that were created.
Expand All @@ -95,8 +95,9 @@ def run_analysis(self, catalog, png_dir, reference_catalog=None, config={}):

# Connect to the catalog.
catalog = intake.open_esm_datastore(catalog)
print(catalog)

if not config:
config = {}
maps = {}
for name, variable in self.metadata.variables().items():
# Filter the catalog down to a single dataset for each variable.
Expand Down

0 comments on commit f8dcd27

Please sign in to comment.