Ouranosinc / PAVICS-landing

The landing page serving as the entrance to PAVICS
1 stars 0 forks source link

ClimateDataAnalysis-5Visualization.ipynb: update for new Jupyter env #30

Closed tlvu closed 3 years ago

tlvu commented 3 years ago

New Jupyter env in https://github.com/Ouranosinc/PAVICS-e2e-workflow-tests/pull/85.

Funny that I have to add NBVAL_IGNORE_OUTPUT to a cell that has empty output!

Error fixed:

  _ PAVICS-landing-master/content/notebooks/climate_indicators/PAVICStutorial_ClimateDataAnalysis-5Visualization.ipynb::Cell 3 _
  Notebook cell execution failed
  Cell 3: Cell outputs differ

  Input:
  # Start with 30 year means from mapping step
  # Calculate weighted average for each region as in last step
  with xr.set_options(keep_attrs=True):
      reg30y_sims = (d30yAvg * weight_masks).sum(dim=['lat','lon'])
      reg30y_ens = xens.ensemble_percentiles(reg30y_sims)
      # make the 'horizon' field the index of our table. rename the 'geom' field to 'region'
      df = reg30y_ens.swap_dims(dict(year='horizon')).rename({'geom':'region'}).to_dataframe()
  df.hvplot.table(title='Summary table',fit_columns=False, sortable=True, selectable=True, width=2000)

  Traceback:
   mismatch 'text/plain'

   assert reference_output == test_output failed:

    ':Table   [ho...ve_delta_p90]' == ':Table   [rc...ve_delta_p90]'
    Skipping 227 identical trailing characters in diff, use -v to show
    - :Table   [rcp,horizon,season,region,tx_mea
    + :Table   [horizon,rcp,region,season,tx_mea
review-notebook-app[bot] commented 3 years ago

Check out this pull request on  ReviewNB

See visual diffs & provide feedback on Jupyter Notebooks.


Powered by ReviewNB