Coder Social home page Coder Social logo

grids-to-climdivs's People

Contributors

adam-allgood avatar avram-meir avatar

Stargazers

 avatar

Watchers

 avatar

grids-to-climdivs's Issues

GridToClimdivs.pm: $mapfile needs to be set by the calling program before package tries to read map data in

Attempt:

use GridToClimdivs qw(get_climdivs);

BEGIN { $GridToClimdivs::mapfile = "../ref/Conus0.125DegreeGrid-ClimateDivisions.map"; }

Result:

Map file must be supplied (e.g., set the variable $GridToClimdivs::mapfile) at /home/avrammeir/work/personal/grids-to-climdivs/lib/perl/GridToClimdivs.pm line 55.
	require GridToClimdivs.pm called at test.pl line 8
	main::BEGIN() called at /home/avrammeir/work/personal/grids-to-climdivs/lib/perl/GridToClimdivs.pm line 0
	eval {...} called at /home/avrammeir/work/personal/grids-to-climdivs/lib/perl/GridToClimdivs.pm line 0
Compilation failed in require at test.pl line 8.
BEGIN failed--compilation aborted at test.pl line 8.

BUG: grids-to-climdivs cannot write output files if output files in config include directories

To reproduce:

  1. grids-to-climdivs.pl takes an --output argument and creates that directory if it does not exist
  2. In the config file passed to grids-to-climdivs.pl via --config, if the filenames in [output] --> files= have a path in them (e.g., %Y/%m/%d/filename), then the script tries to write the resulting climdivs data into $output/%Y/%m/%d/filename. This is expected behavior but since that subdirectory has not been created, there will be an open error.

Solution:
Have to parse the output file directory and attempt to create it, not just the $output arg directory.

Need to handle grids with multiple variables

The sample temperature file config/sample.grid contains multiple grids for different variables. If Regrid::regrid() actually regrids things correctly, the result should be multiple regridded grids. This will fail in GridsToClimDivs->get_climdivs() due to a size mismatch with the map. Need to handle this because a lot of inputs will have multiple variables.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.