Skip to content

Notebook functionise plotting#92

Merged
isaacaka merged 3 commits intomainfrom
notebook_functionise_plotting
Jan 29, 2026
Merged

Notebook functionise plotting#92
isaacaka merged 3 commits intomainfrom
notebook_functionise_plotting

Conversation

@isaacaka
Copy link
Copy Markdown
Collaborator

@isaacaka isaacaka commented Jan 22, 2026

This PR is to functionise the plotting code which is in the Jumper.ipynb notebook:

  • Updates notebook to reflect refactored codebase
  • Functionise plotting code in Jumper.ipynb located in a new file, plotting_utils.py. The plotting logic remains unchanged.
  • Fix linting issues

Closes #93

@isaacaka isaacaka self-assigned this Jan 22, 2026
@review-notebook-app
Copy link
Copy Markdown

Check out this pull request on  ReviewNB

See visual diffs & provide feedback on Jupyter Notebooks.


Powered by ReviewNB

@isaacaka isaacaka force-pushed the notebook_functionise_plotting branch from 9209302 to 349d007 Compare January 22, 2026 10:51
@isaacaka isaacaka requested a review from ma595 January 22, 2026 10:57
Copy link
Copy Markdown
Member

@ma595 ma595 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi Isaac, this is easier to follow, thanks.

Just a few points:

  • Can you check if all the imports are used, i.e. plt, os?
  • Do our linting checks actually check these files? If not, can you please add this.
  • Is there an option to enable you to plot more components for visualisation purposes in the first two rows of the first figure?
  • There seems to be a rogue blank plot in the plot_rmse_depth_profile function..
  • We definitely need more comments in the Jupyter notebook to explain what's going
    on. I also don't really understand what some of the plots are showing. In particular cell 24 and beyond. This can be left to a separate PR.
  • There's some french in the plots i.e. train serie
  • Also the plot dashed lines do not seem to run up to 30 inclusive for the training data. Is this correct?

The commit functionises the plotting code in the Jumper notebook into
reusable functions located in a new file, plotting_utils.py.
Fix french typo in plot label.
The plotting logic remains unchanged.
@isaacaka isaacaka force-pushed the notebook_functionise_plotting branch from 349d007 to 43aeb95 Compare January 27, 2026 17:55
This stops excluding the Jumper notebook and restart files (now removed
from repo) from linting and fixes linting issues. Adds jupyter files
types to pre-commit ruff hook so that notebooks are formatted.
@isaacaka isaacaka force-pushed the notebook_functionise_plotting branch from 43aeb95 to 98dd222 Compare January 27, 2026 18:08
@isaacaka isaacaka requested a review from ma595 January 27, 2026 18:11
@isaacaka
Copy link
Copy Markdown
Collaborator Author

  • Can you check if all the imports are used, i.e. plt, os?

Those are no longer needed after the refactor, will remove them.

  • Do our linting checks actually check these files? If not, can you please add this.

plotting_utils.py has the linting checks done on them. The linting checks is done for all files except specific ones I excluded. The Jumper notebook had been excluded while I refactored the codebase. I have removed the exclusion now.

  • Is there an option to enable you to plot more components for visualisation purposes in the first two rows of the first figure?

Not currently, the functions in general are not fully parametrized. I have mostly kept them as is, bar functionising them for now. Plan to do this in step 3 (sub-issue #95) of issue #94

  • There seems to be a rogue blank plot in the plot_rmse_depth_profile function..

Yes, will fixed

  • We definitely need more comments in the Jupyter notebook to explain what's going
    on. I also don't really understand what some of the plots are showing. In particular cell 24 and beyond. This can be left to a separate PR.

Overall we are replacing this single notebook with a set of example notebooks, this will be done in step 5 of issue #94. I created a larger issue for this to track the work. It will make it easier to see where this PR fits in the overall plan.

  • There's some french in the plots i.e. train serie

Yes, will add the 's'

  • Also the plot dashed lines do not seem to run up to 30 inclusive for the training data. Is this correct?

Yes, it goes from 0 to 29 rather than 1 to 30, so 30 values in total.

Copy link
Copy Markdown
Member

@ma595 ma595 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the fixes. Ready to merge.

@isaacaka isaacaka merged commit 233adce into main Jan 29, 2026
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

Functionise plotting code in Notebook

2 participants