Skip to content

Commit

Permalink
Add typos and fix typos
Browse files Browse the repository at this point in the history
  • Loading branch information
jochenklar committed Jul 10, 2024
1 parent 8587111 commit a8b6778
Show file tree
Hide file tree
Showing 14 changed files with 31 additions and 17 deletions.
4 changes: 4 additions & 0 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -10,3 +10,7 @@ repos:
- id: end-of-file-fixer
- id: trailing-whitespace
- id: debug-statements
- repo: https://github.com/crate-ci/typos
rev: v1.23.1
hooks:
- id: typos
9 changes: 9 additions & 0 deletions .typos.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
[default.extend-words]
ba = "ba"
strat = "strat"
whe = "whe"
mis = "mis"
hassel = "hassel"
Hassel = "Hassel"
noy = "noy"
pn = "pn"
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,14 +14,14 @@ your updates will be visible at `https://protocol.isimip.org`.
As a rule, the sector-specific text should be kept to a minimum and cover
as much structure as possible by machine-readable code under [definitions](definitions/).

The React JavaScript app is build in a seperate step which are described under [app/README.md]([app/README.md]).
The React JavaScript app is build in a separate step which are described under [app/README.md]([app/README.md]).

Setup
-----

Building the protocol needs git and a recent Python version (> 3.6). The installation of Python (and its developing packages), however differs from operating system to operating system. Instructions can be found [here](https://github.com/ISI-MIP/isimip-qc/blob/main/README.md#prerequisites).

If you work with different Python applications, we recommend to create a virtual enviroment for the protocol.
If you work with different Python applications, we recommend to create a virtual environment for the protocol.

```bash
# setup venv on Linux/macOS/Windows WSL
Expand Down
2 changes: 1 addition & 1 deletion app/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -28,4 +28,4 @@ In order to rebuild the app or work on the code, the following setup needs to be
5. Run `python3 build/assets.py --link` or `make dev` in the main protocol directory to link the assets instead of copying them.
6. Before commiting any changes, run `npm run build:prod` or just `make` to create a production version of the app, which then will be part of the repository.
6. Before committing any changes, run `npm run build:prod` or just `make` to create a production version of the app, which then will be part of the repository.
2 changes: 1 addition & 1 deletion app/src/app.js
Original file line number Diff line number Diff line change
Expand Up @@ -139,7 +139,7 @@ setTimeout(() => {
})

setTimeout(() => {
// scroll to anchor or position once everthing is settled
// scroll to anchor or position once everything is settled
if (anchor) {
anchor.scrollIntoView()
}
Expand Down
4 changes: 2 additions & 2 deletions app/src/components/badges/Sectors.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ const Sectors = ({ config, sectors }) => {
if (sectors === undefined) {
return <span className="badge badge-success badge-sector">all sectors</span>
} else if (sectors === []) {
// by setting `sectors: []` the display of sectors can be ommited
// by setting `sectors: []` the display of sectors can be omitted
return null
} else if (sectors === null) {
// for the title just display the configured sectors
Expand All @@ -17,7 +17,7 @@ const Sectors = ({ config, sectors }) => {
return <span className="badge badge-success badge-sector">all sectors</span>
}
} else {
// some sectors are configured -> hightlight selected sectors
// some sectors are configured -> highlight selected sectors
if (config.sectors !== undefined && config.sectors.length > 0) {
// at least one sector is selected
return sectors.map((sector, index) => {
Expand Down
8 changes: 4 additions & 4 deletions build/protocol.py
Original file line number Diff line number Diff line change
Expand Up @@ -63,8 +63,8 @@ def main():
protocol_path = Path('protocol') / '00.base.md'
template_string = protocol_path.read_text()

enviroment = Environment(loader=FileSystemLoader(['bibliography', 'protocol', 'templates']))
template = enviroment.from_string(template_string)
environment = Environment(loader=FileSystemLoader(['bibliography', 'protocol', 'templates']))
template = environment.from_string(template_string)

md = template.render(commit_url=commit_url, commit_hash=commit_hash, commit_date=commit_date)
html = markdown(md, extensions=[
Expand All @@ -84,10 +84,10 @@ def main():
template_path = Path('templates') / 'layout.html'
output_path = Path('output') / 'index.html'
output_path.parent.mkdir(parents=True, exist_ok=True)
enviroment = Environment(loader=FileSystemLoader(['templates']))
environment = Environment(loader=FileSystemLoader(['templates']))

with open(template_path, encoding='utf-8') as f:
template = enviroment.from_string(f.read())
template = environment.from_string(f.read())

with open(output_path, 'w', encoding='utf-8') as f:
f.write(template.render(html=html, definitions=json.dumps(definitions, indent=2), patterns=json.dumps(patterns, indent=2)))
Expand Down
2 changes: 1 addition & 1 deletion definitions/climate_variable/lightning.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@
path: ISIMIP3b/InputData/climate/lightning/lightning_ukesm1-0-ll_<climate-scenario>_global_monthly_2010_2100.nc
comment: >-
Source: [Kaplan, Jed O., et al. 2023](https://doi.org/10.5281/zenodo.7511843).
This is the input data for the `varlightning` sensitivity experiments. Seperate
This is the input data for the `varlightning` sensitivity experiments. Separate
datasets are available for ssp126, ssp370, and ssp585. Please note, as this dataset
is produced using UKESM output, modelers should only use this data together with
UKESM climate forcing.
Expand Down
2 changes: 1 addition & 1 deletion definitions/geo_dataset.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -508,7 +508,7 @@

- specifier: lake_elevation
specifier_file: elevation
title: Lake Heigth
title: Lake Height
group: lakes
resolution: 0.5° grid
path:
Expand Down
2 changes: 1 addition & 1 deletion definitions/product.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
title: Secondary Input Data
description: >-
Data that have been derived from or are related to the input data, but not described
in the simulation protocol (e.g. with a differnt spatial or temporal resolution).
in the simulation protocol (e.g. with a different spatial or temporal resolution).
- specifier: OutputData
title: Output Data
Expand Down
4 changes: 2 additions & 2 deletions definitions/variable/peat.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@
- null
- <pt>
units: m
frequency: daily if possible, else montly
frequency: daily if possible, else monthly
resolution: 0.5° grid
comment: >-
Water table level relative to the ground surface. Note that a negative value should
Expand Down Expand Up @@ -192,7 +192,7 @@
- null
- <pt>
units: '1'
frequency: daily if possible, else montly
frequency: daily if possible, else monthly
resolution: 0.5° grid
comment: >-
Grid fraction that is flooded, i.e. where the water table is above ground surface.
Expand Down
2 changes: 1 addition & 1 deletion protocol/02.experiments.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

In Table 2.1, we describe the different experiments for ISIMIP3. Each default experiment is defined by its **climate related forcing (CRF)** and the assumptions regarding **direct human forcing (DHF)**. The associated specifications all have a label such as `obsclim` or `histsoc` that are provided in Table 2.1 and further specified in Tables 2.2 and 2.3. These specifiers are used in the file names of the corresponding input files and should also be used for the names of the output files (see report model results [report model results](#5-reporting-model-results)). Sensitivity experiments are described as deviation from a default experiment and represented by labels that are used as a third specifier of the experiments. Their specific meanings are defined in Table 2.4.

Please note that the experiments are different for ISIMIP3a and ISIMIP3b and some are sector specific. You can use the menu on the top-right of the page to select the sumulation round and sectors you are interested in.
Please note that the experiments are different for ISIMIP3a and ISIMIP3b and some are sector specific. You can use the menu on the top-right of the page to select the simulation round and sectors you are interested in.

::: table identifier=experiments caption="Table 2.1: Experiment set-up. Each experiment is specified by the climate related forcing (top row) and the direct human forcing (bottom row). Sensitivity labels indicate deviations from the default settings. Experiments are colored by group: group I (grey), group II (red) and group III (blue). The subtitles in the first row indicate how the experiment is defined in filenames."

Expand Down
2 changes: 1 addition & 1 deletion protocol/04.output.md
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@ Many variables are defined per area (unit m-2). Typically, and unless otherwise

#### Information about soil organic carbon pools of different turnover times

Some variables can be provided seperately by soil organic carbon pools of different turnover times, if your model simulates those. This is done using the `-<pool>` extension. Please indicate them as `-fast`, `-slow`, and `-passive` and describe your definition of the turnover times in your model description. The extension is used in addition to the extension expressing the Plant Functional Type (PFT) and needs to put before it.
Some variables can be provided separately by soil organic carbon pools of different turnover times, if your model simulates those. This is done using the `-<pool>` extension. Please indicate them as `-fast`, `-slow`, and `-passive` and describe your definition of the turnover times in your model description. The extension is used in addition to the extension expressing the Plant Functional Type (PFT) and needs to put before it.

::: show sector=peat

Expand Down
1 change: 1 addition & 0 deletions requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -5,3 +5,4 @@ jsonschema
markdown-customblocks
pre-commit
PyYAML
typos

0 comments on commit a8b6778

Please sign in to comment.