Developer’s guide

The tool provides a set of useful diagnostics, but a lot more can be required at anytime. If you miss something and are able to develop it, you are more than welcome to collaborate. Even if you can not develop it, please let us know what do you want.

The first step is to go to the GitLab page for the project ( https://earth.bsc.es/gitlab/es/ocean_diagnostics/ ) and open a new issue. Be sure that the title is self-explicative and give a detailed description of what you want. Please, be very explicit about what you want to avoid misunderstandings.

Hint

If reading your description, you think that you are taking the developers as stupids, you are doing it perfectly.

Don’t forget to add the relevant tags. At this stage you will have to choose between ‘enhancement’, if you are proposing an improvement on a currently available feature, or ‘new feature’ in any the other case.

Now, if you are thinking on developing it yourself, please refer to the BSC-ES Git strategy ( wiki_link_when_available ) If you have any doubts, or just want help to start the development, contact javier.vegas@bsc.es.

Developing a diagnostic

For new diagnostics development, we have some advice to give:

  • Do not worry about performance at first, just create a version that works. Developers can help you to optimize it later.
  • There is nothing wrong with doing some common preparations in the generate_jobs of the diagnostic.
  • Parallelization is achieved by running multiple diagnostics at a time. You don’t need to implement it at diagnostic level
  • Use the smallest time frame for your diagnostic: if you can work at chunk level, do not ask for full year data.
  • Prefer NCO over CDO, you will have less problems when versions change.
  • Ask for help as soon as you get stuck.
  • Use always the methods in Utils instead of writing your own code.
  • Use meaningful variable names. If you are using short names just to write less, please switch to an editor with autocompletion!
  • Do not modify the mesh and mask files, another diagnostic can be using them at the same time.