Skip to content

Commit

Permalink
Feature/move docs (#43)
Browse files Browse the repository at this point in the history
* Move DIACOV documentation

* DFS

* Remove DFS again

* Documentation updates
  • Loading branch information
ewhelan authored Mar 14, 2024
1 parent 2241a65 commit a89cd3b
Show file tree
Hide file tree
Showing 5 changed files with 95 additions and 100 deletions.
86 changes: 2 additions & 84 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@
Collection of ACCORD DA tools. So far we have jbdiagnose and associated plotting.

Desirables:
- diacov
- festat
- TuneBR
- obstat
Expand All @@ -13,14 +12,14 @@ Desirables:
cd AccordDaTools
mkdir build
cd build
cmake .. -DCMAKE_INSTALL_PREFIX=/path/to/da_tools
cmake .. -DCMAKE_INSTALL_PREFIX=/path/to/da_tools
make
ctest
make install
```
Add DA Tools to your PATH:
```
export PATH=/path/to/da_tools:$PATH
export PATH=/path/to/da_tools/bin:$PATH
```

## Tools
Expand Down Expand Up @@ -59,85 +58,4 @@ Example:
```
plotjbdiag -l 50 -t vercor -p QQ -r ./ -e IRELAND75L65
```
### VarBC
#### VARBC.cycle data extraction
Help/usage:
```
varbcdiagnose -h
```

Example:
```
varbcdiagnose -i /path/to/directory/with/varbc_files/ -o varbc_diag_out
```

#### VarBC coefficient time-series plotting
Help/usage:
```
plotvarbccoeff -h
```

Example:
```
plotvarbccoeff -i varbc_diag_out/VARBC_3_16_3309_210000 -b
```

### DFS
#### DFS computation
The dfscomp tool reads the (ASCII) data from an unperturbed CCMA and a perturbed CCMA.

Help/usage:
```
dfscomp -h
```

Example:
```
dfscomp -p CCMA_2022050112.dat -u CCMA_2022050112_unpert.dat -o dfs2022050112.dat
```

### DIACOV
First, you should have Festat output and the DIACOV binary compiled by Harmonie stored somewhere.
Then, create the new directory, Jb files there. Example:
```
mkdir DiacovTest
cd DiacovTest
mkdir dataTest
cp /path/to/Jb/data dataTest/.
```
#### Run Diacov
Use rundiacov script to initiate the processing of the Jb files.
Help/usage:
```
rundiacov -h
```

Example:
```
rundiacov -i dataTest -c METCOOP25D_65_2021100300-2021111006_412 -g 2.5 -d /path/to/DIACOV
```

#### Produce diagonal stats
When you get DIACOV output, use diag_diacov script to produce stats in ASCII format, which are suitable for further plotting.
Help/usage:
```
diag_diacov -h
```

Example:
```
diag_diacov -i dataTest -o stats
```

#### Produce plots
Use plotdiacov script to produce the plots from ACSII files.
Help/usage:
```
plotdiacov -h
```

You can either produce the plots for all of the available stat files, or to choose specific ones. Examples:
```
plotdiacov -d ./stats (the plots will be saved to the same directory as stat files)
plotdiacov -i ./stats/corqu65.dat -o ./stats/corqu65.png (if the output file name is not specified, the plot is saved to the pwd with the default name "output.png")
```
3 changes: 2 additions & 1 deletion doc/make.jl
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,8 @@ using Documenter
pages = [
"Jb diagnose" => "jbdiagnose.md",
"cv header list" => "cvheaderlist.md",
"VarBc Coeff" => "varbccoeff.md"
"VarBc Coeff" => "varbccoeff.md",
"DIACOV" => "diacov.md"
]

prettyurls = get(ENV, "CI", nothing) == "true"
Expand Down
15 changes: 15 additions & 0 deletions doc/src/dfs.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
#DFS

## DFS computation
The dfscomp tool reads the (ASCII) data from an unperturbed CCMA and a perturbed CCMA.

Help/usage:
```
dfscomp -h
```

Example:
```
dfscomp -p CCMA_2022050112.dat -u CCMA_2022050112_unpert.dat -o dfs2022050112.dat
```

53 changes: 53 additions & 0 deletions doc/src/diacov.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,53 @@
# DIACOV

[TOC]

## Background
1. First, you should have Festat output and the DIACOV binary compiled by Harmonie stored somewhere.
2. Then, create the new directory, copy the DIACOV binary and Jb files there. Example:

## Tools
```
mkdir DiacovTest
cd DiacovTest
cp /path/to/DIACOV .
mkdir dataTest
cp /path/to/Jb/data dataTest/.
```
#### Run Diacov
Use rundiacov script to initiate the processing of the Jb files.
Help/usage:
```
rundiacov -h
```

Example:
```
rundiacov -i dataTest -c METCOOP25D_65_2021100300-2021111006_412 -g 2.5 -d /path/to/DIACOV
```

#### Produce diagonal stats
When you get DIACOV output, use diag_diacov script to produce stats in ASCII format, which are suitable for further plotting.
Help/usage:
```
diag_diacov -h
```

Example:
```
diag_diacov -i dataTest -o stats
```

#### Produce plots
Use plotdiacov script to produce the plots from ACSII files.
Help/usage:
```
plotdiacov -h
```

You can either produce the plots for all of the available stat files, or to choose specific ones. Examples:
```
plotdiacov -d ./stats # the plots will be saved to the same directory as stat files
plotdiacov -i ./stats/corqu65.dat -o ./stats/corqu65.png # if the output file name is not specified, the plot is saved to the pwd with the default name "output.png"
```

38 changes: 23 additions & 15 deletions doc/src/varbccoeff.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,21 +5,19 @@

This diagnostic tool is intended for use in the evaluation of the performance of the variational bias correction (VarBC) used for satellite observations in the context of HARMONIE-AROME data assimilation systems. In particular for evaluating the performance in time of the VarBC coefficients.


## 2. Content

The tool comprises two scripts:

There are tool two tools required:
- **varbcdiagnosis** for data extraction

- **plotvarbccoeff** for VarBC coefficient time-series plotting

## 3. Usage
## 2. Tools

**varbcdiagnosis** extracts VarBC coefficients for a certain satellite/instrument and all the channels with data and for
a certain period of time. VarBC coefficients are extracted from VARBC.cycle files.
### VARBC.cycle data extraction

Script **varbcdiagnosis** arguments:
**varbcdiagnose** extracts VarBC coefficients for a certain satellite/instrument and all the channels with data and for a certain period of time. VarBC coefficients are extracted from VARBC.cycle files.

Help/usage:
```shell
$~> varbcdiagnose -h

-i input-directory
where VARBC.cycle files are stored, usually in the form ./EXP/YYYY/MM/DD/HH (EXPERIMENT, Year, Month, Day and Hour)
Expand All @@ -35,21 +33,31 @@ Script **varbcdiagnosis** arguments:
See https://apps.ecmwf.int/odbgov/sensor/ for more details.

-h Help! Print usage information.
```

Example:
```shell
$~> varbcdiagnose -i /path/to/directory/with/varbc_files/ -o varbc_diag_out
```

**plotvarbccoeff** produces a plot for a selected satellite, sensor, channel and hour (optional, if not present all the assimilation cycles with observations are included).
### VarBC coefficient time-series plotting

Script **plotvarbccoef** arguments:
**plotvarbccoeff** produces a plot for a selected satellite, sensor, channel and hour (optional, if not present all the assimilation cycles with observations are included).

Help/usage:
```
$~> plotvarbccoeff -h
-h, --help show this help message and exit
-i IPATH Input file name
-l LLOC Legend location using matplotlib syntax
-d LABELS Optional experiment description
-b Batch mode, produce png only
```

For example for METOP-B (3), MHS (15), Channel 9 at 21 UTC (or at all assimilation cycles with data), IPATH is
output-directory/VARBC_3_15_9_210000 (or output-directory/VARBC_3_15_9).

Example: For METOP-B (3), MHS (15), Channel 9 at 21 UTC (or at all assimilation cycles with data), IPATH is output-directory/VARBC_3_15_9_210000 (or output-directory/VARBC_3_15_9).
```
plotvarbccoeff -i varbc_diag_out/VARBC_3_16_3309_210000 -b
```

## 4. Interpretation

Expand Down

0 comments on commit a89cd3b

Please sign in to comment.