I'd like to experiment with this workbench but so far, everything I have tried has been broken...

REPRO 1: test fails
------------------------

$ git clone https://github.com/apache/climate.git
$ cd climate
$ git log | head
commit 90b1b9ffe32d21af97f5437253f9621a14ec557f
Merge: d98d172 21fe4ea
Author: huikyole <huiky...@argo.jpl.nasa.gov>
Date:   Tue Jan 10 08:19:40 2017 -0800

    CLIMATE-894 - Debugging regrid_spatial_mask

$ ./test.sh
...

======================================================================
FAIL: test_odd_nice_intervals (ocw.tests.test_plotter.TestNiceIntervalsFunction)
----------------------------------------------------------------------
Traceback (most recent call last):
File "/home/toddg/projects/climate/climate/ocw/tests/test_plotter.py", line 46, in test_odd_nice_intervals
    np.testing.assert_array_equal(result, expected_array)
File "/opt/anaconda3/envs/python27/lib/python2.7/site-packages/numpy/testing/utils.py", line 871, in assert_array_equal
    verbose=verbose, header='Arrays are not equal')
File "/opt/anaconda3/envs/python27/lib/python2.7/site-packages/numpy/testing/utils.py", line 796, in assert_array_compare
    raise AssertionError(msg)
AssertionError:
Arrays are not equal

(mismatch 80.0%)
 x: array([-1.6, -0.8,  0. ,  0.8,  1.6])
 y: array([-2., -1.,  0.,  1.,  2.])

----------------------------------------------------------------------
Ran 206 tests in 126.232s

FAILED (failures=1)

REPRO 2: examples fail
-------------------------------
(python27) [toddg@dino examples (master)]$ python simple_model_to_model_bias.py Loading /tmp/AFRICA_KNMI-RACMO2.2b_CTL_ERAINT_MM_50km_1989-2008_tasmax.nc into an OCW Dataset Object
KNMI_Dataset.values shape: (times, lats, lons) - (240, 201, 194)

Loading /tmp/AFRICA_UC-WRF311_CTL_ERAINT_MM_50km-rg_1989-2008_tasmax.nc into an OCW Dataset Object
WRF_Dataset.values shape: (times, lats, lons) - (240, 201, 194)

Temporally Rebinning the Datasets to an Annual Timestep
KNMI_Dataset.values shape: (20, 201, 194)
WRF_Dataset.values shape: (20, 201, 194)


The KNMI_Dataset spatial bounds (min_lat, max_lat, min_lon, max_lon) are:
(-45.7599983215332, 42.2400016784668, -24.639999389648438, 60.279998779296875)

The KNMI_Dataset spatial resolution (lat_resolution, lon_resolution) is:
(0.43999863, 0.44000053)


Spatially Regridding the KNMI_Dataset...
Traceback (most recent call last):
  File "simple_model_to_model_bias.py", line 79, in <module>
    knmi_dataset = dsp.spatial_regrid(knmi_dataset, new_lats, new_lons)
File "/opt/anaconda3/envs/python27/lib/python2.7/site-packages/ocw/dataset_processor.py", line 301, in spatial_regrid
    values_original.data[idx] = q_shifted[idx]
File "/opt/anaconda3/envs/python27/lib/python2.7/site-packages/numpy/ma/core.py", line 3168, in __getitem__
    dout = self.data[indx]
IndexError: in the future, 0-d boolean arrays will be interpreted as a valid boolean index

-Todd

Reply via email to