Skip to content

Commit

Permalink
Move some more developer content to development.md
Browse files Browse the repository at this point in the history
Fixes #165.
  • Loading branch information
alexdewar committed Jul 20, 2023
1 parent cdc25b5 commit 18aec60
Show file tree
Hide file tree
Showing 2 changed files with 39 additions and 39 deletions.
38 changes: 0 additions & 38 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -32,44 +32,6 @@ For more information, see the [developer guide].

[developer guide]: https://imperialchepi.github.io/healthgps/development

### Optional: Running `pre-commit` hooks

It is recommended that developers install [`pre-commit`](https://pre-commit.com/) to
make use of [the hooks](./.pre-commit-config.yaml) we have installed for this
repository. (Note that this step is only for Health-GPS developers, not end users!)

Once you have [installed `pre-commit`](https://pre-commit.com/#installation), you should
install the hooks into your local clone of the Health-GPS repository, like so:

```cmd
> pre-commit install
```

Now, every time attempt to make a git commit, your changes will be checked against the
`pre-commit` hooks.

### Optional: Performing static analysis with `clang-tidy`

[`clang-tidy`] is a static analysis tool based on clang, which can identify bugs and
stylistic problems with C++ code. It comes with a helper script, `run-clang-tidy`, which
allows you to run `clang-tidy` across your CPU cores.

You need to tell it the path to the `compile_commands.json` file, which is generated by
CMake, like so (on Linux):

```cmd
> run-clang-tidy -p out/build/linux-debug
```

`clang-tidy` can automatically generate fixes for some problems. To do this, pass the
`-export-fixes` flag with a file path to the script. The fixes can be applied with the
included `clang-apply-replacements` tool.

`clang-tidy` is also used by the CI system to lint any new code added to Health-GPS via
a pull request.

[`clang-tidy`]: https://clang.llvm.org/extra/clang-tidy/

## License

The code in this repository is licensed under the [BSD 3-Clause](LICENSE.txt) license.
Expand Down
40 changes: 39 additions & 1 deletion docs/development.md
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,44 @@ ctest --preset='core-test-linux'

All available options are defined using CMake *presets* in the `CMakePresets.json` file, which also declare *build presets* and other options previously provided to [CMake](https://cmake.org/) via command line arguments. The use of *presets* provides consistent build scripts across development and CI/CD environments using source control for reproducibility.

## Optional: Running `pre-commit` hooks

It is recommended that developers install [`pre-commit`](https://pre-commit.com/) to
make use of [the hooks](./.pre-commit-config.yaml) we have installed for this
repository. (Note that this step is only for Health-GPS developers, not end users!)

Once you have [installed `pre-commit`](https://pre-commit.com/#installation), you should
install the hooks into your local clone of the Health-GPS repository, like so:

```cmd
> pre-commit install
```

Now, every time attempt to make a git commit, your changes will be checked against the
`pre-commit` hooks.

## Optional: Performing static analysis with `clang-tidy`

[`clang-tidy`] is a static analysis tool based on clang, which can identify bugs and
stylistic problems with C++ code. It comes with a helper script, `run-clang-tidy`, which
allows you to run `clang-tidy` across your CPU cores.

You need to tell it the path to the `compile_commands.json` file, which is generated by
CMake, like so (on Linux):

```cmd
> run-clang-tidy -p out/build/linux-debug
```

`clang-tidy` can automatically generate fixes for some problems. To do this, pass the
`-export-fixes` flag with a file path to the script. The fixes can be applied with the
included `clang-apply-replacements` tool.

`clang-tidy` is also used by the CI system to lint any new code added to Health-GPS via
a pull request.

[`clang-tidy`]: https://clang.llvm.org/extra/clang-tidy/

## HPC Build

Although Health-GPS is compatible with most High Performance Computing (HPC) system, this section contents are specific for using *Health-GPS software* at the *Imperial College London* [HPC system](https://www.imperial.ac.uk/admin-services/ict/self-service/research-support/rcs/), which users need to register to *get access* and support. The HPC is **Linux** based, therefore users *must* be familiar with *Unix command line* and *shell script* to properly navigate the file system, build programs, run applications, and automate repetitive tasks. See the [User Guide](userguide#50-hpc-running) for a very brief introduction to Imperial HPC system.
Expand Down Expand Up @@ -153,7 +191,7 @@ HealthGPS.Console -f healthgps/example/France.Config.json -s ~/healthgps/data

In general, you should avoid running you own applications on the shared HPC login nodes, the *etiquette* for working with HPC system is the create and submit jobs to be evaluated by the HPC nodes instead. See the [User Guide](userguide#50-hpc-running) for details on how to use the installed Health-GPS modules on the Imperial HPC system.

# Implementation
## Implementation

The software application provides a Command Line Interface (CLI) for the user to inform the configuration to run and backend storage location. The experiment options are provided to the model via a configuration file (JSON format), including population size, intervention scenarios and number of runs.

Expand Down

0 comments on commit 18aec60

Please sign in to comment.