|
|
|
> This tutorial gives a short overview how to create your own Nomad Beaker Notebooks and comply to the current cooperate design and branding of the Nomad Laboratory group.
|
|
|
|
|
|
|
|
## Setup
|
|
|
|
|
|
|
|
Start your project in a separate [nomad-lab](https://gitlab.rzg.mpg.de/nomad-lab/) repository prefixed by the string **notebook-**. Please choose a meaningful lower-case name, hyphenate separated words. You may use a slugify generator (https://blog.tersmitten.nl/slugify) to comply to the format. A good repository name for example is "*notebook-periodic-table*" and a bad one is "*notebook-pt*".
|
|
|
|
|
|
|
|
## Structure
|
|
|
|
|
|
|
|
Structure your repository as seen in the following, where *notebook-nomad-template* is the name of the imaginary Beaker notebook we want to create:
|
|
|
|
|
|
|
|
```bash
|
|
|
|
notebook-nomad-template
|
|
|
|
├── beaker-notebooks
|
|
|
|
│ └── notebook-nomad-template.bkr
|
|
|
|
├── example-data
|
|
|
|
│ └── notebook-nomad-template
|
|
|
|
├── LICENSE
|
|
|
|
├── README.md
|
|
|
|
└── requirements.txt
|
|
|
|
```
|
|
|
|
|
|
|
|
For your project, there already exists a default Nomad Beaker Notebook Template ([download](/uploads/7e70bdcc40cc527e1be3af2a5cf52e26/notebook-nomad-template.bkr)), which will be updated regularly. Thus, you don't have to start from scratch and you can start coding. You only have to replace all the place-holders given in the notebook.
|
|
|
|
|
|
|
|
There, also exists a pre-made `LICENSE` file ([download](/uploads/7809c0a85d943b7361a2e10126b7594b/LICENSE)) you can directly copy into your project. By default, we use **Apache License 2.0** and a nice overview of the licences conditions gives https://choosealicense.com/licenses/apache-2.0/ .
|
|
|
|
|
|
|
|
The `requirements.txt` is there if you need special python libraries for your notebook, i.e., `numpy`, that can be installed via pip (https://pypi.python.org/pypi). Please list the needed libraries as a plain text file with one name per line.
|
|
|
|
|
|
|
|
If you need additional files, please store them in the `example-data/notebook-nomad-template` folder.
|
|
|
|
|
|
|
|
## Release
|
|
|
|
|
|
|
|
Once you have finished your notebook and it was reviewed by your supervisors or group members, you are ready to put all your files into the [Nomad Analytics Toolkit Tutorials repository] (https://gitlab.rzg.mpg.de/nomad-lab/analytics-toolkit-tutorials). Just copy your `example-data/notebook-nomad-template` folder into the repository's [`example-data` folder](https://gitlab.rzg.mpg.de/nomad-lab/analytics-toolkit-tutorials/tree/master/example-data) and your notebook into the repository's [`beaker-notebook` folder](https://gitlab.rzg.mpg.de/nomad-lab/analytics-toolkit-tutorials/tree/master/beaker-notebooks). You may adjust your paths in your notebook, do a commit, and that's it! :sunny: |
|
|
|
\ No newline at end of file |