Skip to content

Commit

Permalink
Merge branch 'main' into dependabot/pip/urllib3-2.0.7
Browse files Browse the repository at this point in the history
  • Loading branch information
jgroehl authored Jun 22, 2024
2 parents 6639cd3 + b2c2461 commit 69b1a9d
Show file tree
Hide file tree
Showing 32 changed files with 1,328 additions and 940 deletions.
6 changes: 3 additions & 3 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ repos:
- id: check-added-large-files # prevents adding large files, above 500kB

- repo: https://github.com/pre-commit/mirrors-autopep8 # Uses MIT-License (MIT compatible)
rev: v2.0.2 # Use the sha / tag you want to point at
rev: v2.0.4 # Use the sha / tag you want to point at
hooks:
- id: autopep8 # formats code according to PEP8 standard. Lets commit fail if it needs to reformat code. Config for autopep8 is done in myproject.toml

Expand All @@ -17,7 +17,7 @@ repos:
- id: validate-cff # validates cff citation files

- repo: https://github.com/Lucas-C/pre-commit-hooks # Uses MIT License (MIT compatible)
rev: v1.5.1
rev: v1.5.4
hooks:
- id: insert-license # Checks if the license header specified at license_header.txt is added in the first lines of each python file. If not, it suggests to insert them.
types: [python]
Expand All @@ -31,7 +31,7 @@ repos:
- id: gitlint

- repo: https://github.com/tcort/markdown-link-check # Uses ISC-License (MIT compatible)
rev: v3.10.3
rev: v3.11.2
hooks:
- id: markdown-link-check # checks if links in markdown files work
exclude: docs/
Expand Down
13 changes: 5 additions & 8 deletions .readthedocs.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,16 +3,13 @@ version: 2

# Set the version of Python and other tools you might need
build:
os: ubuntu-20.04
tools: {python: "3.9"}
os: ubuntu-22.04
tools: {python: "3.10"}
jobs:
pre_create_environment:
- asdf plugin add poetry
- asdf install poetry latest
- asdf global poetry latest
- poetry config virtualenvs.create true
post_create_environment:
- pip install poetry
post_install:
- poetry install
- VIRTUAL_ENV=$READTHEDOCS_VIRTUALENV_PATH poetry install --with docs

# Build documentation in the docs/ directory with Sphinx
sphinx:
Expand Down
24 changes: 6 additions & 18 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -75,25 +75,13 @@ acoustic simulations possible.

### mcx (Optical Forward Model)

Either download suitable executables or build yourself from the following sources:
Download the latest nightly build of [mcx](http://mcx.space/) on [this page](http://mcx.space/nightly/github/) for your operating system:

[http://mcx.space/](http://mcx.space/)
- Linux: `mcx-linux-x64-github-latest.zip`
- MacOS: `mcx-macos-x64-github-latest.zip`
- Windows: `mcx-windows-x64-github-latest.zip`

In order to obtain access to all custom sources that we implemented, please build mcx yourself from the
following mcx Github fork:
[https://github.com/IMSY-DKFZ/mcx](https://github.com/IMSY-DKFZ/mcx)

For the installation, please follow steps 1-4:
1. `git clone https://github.com/IMSY-DKFZ/mcx.git`
2. `cd mcx/src`
3. In `MAKEFILE` adapt line 111 the sm version [according to your GPU](https://arnon.dk/matching-sm-architectures-arch-and-gencode-for-various-nvidia-cards/).
4. `make`

The built binary can be found in `src/bin`.
Note, in case you can’t build mcx with the GPU-specific sm version you need to install a more recent NVIDIA driver and nvcc toolkit.
One option would be to install cuda in a conda environment via `conda install cuda -c nvidia`.
Please note that there might be compatibility issues using mcx-cl with the MCX Adapter as this use case is not
being tested and supported by the SIMPA developers.
Then extract the files and set `MCX_BINARY_PATH=/.../mcx/bin/mcx` in your path_config.env.

### k-Wave (Acoustic Forward Model)

Expand Down Expand Up @@ -233,4 +221,4 @@ Gröhl, Janek, Kris K. Dreher, Melanie Schellenberg, Tom Rix, Niklas Holzwarth,

This project has received funding from the European Research Council (ERC) under the European Union’s Horizon 2020 research and innovation programme (grant agreement No. [101002198]).

![ERC](docs/source/images/LOGO_ERC-FLAG_EU_.jpg "ERC")
![ERC](docs/source/images/LOGO_ERC-FLAG_EU_.jpg "ERC")
30 changes: 8 additions & 22 deletions docs/source/introduction.md
Original file line number Diff line number Diff line change
Expand Up @@ -39,25 +39,13 @@ acoustic simulations possible.

### mcx (Optical Forward Model)

Either download suitable executables or build yourself from the following sources:
Download the latest nightly build of [mcx](http://mcx.space/) on [this page](http://mcx.space/nightly/github/) for your operating system:

[http://mcx.space/](http://mcx.space/)
- Linux: `mcx-linux-x64-github-latest.zip`
- MacOS: `mcx-macos-x64-github-latest.zip`
- Windows: `mcx-windows-x64-github-latest.zip`

In order to obtain access to all custom sources that we implemented, please build mcx yourself from the
following mcx Github fork:
[https://github.com/IMSY-DKFZ/mcx](https://github.com/IMSY-DKFZ/mcx)

For the installation, please follow steps 1-4:
1. `git clone https://github.com/IMSY-DKFZ/mcx.git`
2. `cd mcx/src`
3. In `MAKEFILE` adapt line 111 the sm version [according to your GPU](https://arnon.dk/matching-sm-architectures-arch-and-gencode-for-various-nvidia-cards/).
4. `make`

The built binary can be found in `src/bin`.
Note, in case you can’t build mcx with the GPU-specific sm version you need to install a more recent NVIDIA driver and nvcc toolkit.
One option would be to install cuda in a conda environment via `conda install cuda -c nvidia`.
Please note that there might be compatibility issues using mcx-cl with the MCX Adapter as this use case is not
being tested and supported by the SIMPA developers.
Then extract the files and set `MCX_BINARY_PATH=/.../mcx/bin/mcx` in your path_config.env.

### k-Wave (Acoustic Forward Model)

Expand All @@ -67,12 +55,10 @@ for further (and much better) guidance under:
[http://www.k-wave.org/](http://www.k-wave.org/)

1. Install MATLAB with the core, image processing and parallel computing toolboxes activated at the minimum.
2. Download the kWave toolbox
2. Download the kWave toolbox (version >= 1.4)
3. Add the kWave toolbox base path to the toolbox paths in MATLAB
4. Download the kWaveArray addition from the link given in this user forum post [http://www.k-wave.org/forum/topic/alpha-version-of-kwavearray-off-grid-sources](http://www.k-wave.org/forum/topic/alpha-version-of-kwavearray-off-grid-sources)
5. Add the kWaveArray folder to the toolbox paths in MATLAB as well
6. If wanted: Download the CPP and CUDA binary files and place them in the k-Wave/binaries folder
7. Note down the system path to the `matlab` executable file.
4. If wanted: Download the CPP and CUDA binary files and place them in the k-Wave/binaries folder
5. Note down the system path to the `matlab` executable file.

## Path management

Expand Down
6 changes: 6 additions & 0 deletions docs/source/simpa.utils.rst
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,12 @@ utils
:show-inheritance:


.. automodule:: simpa.utils.matlab
:members:
:undoc-members:
:show-inheritance:


.. automodule:: simpa.utils.path_manager
:members:
:undoc-members:
Expand Down
8 changes: 4 additions & 4 deletions docs/source/simpa_examples.rst
Original file line number Diff line number Diff line change
Expand Up @@ -4,12 +4,12 @@ simpa\_examples
.. toctree::
:maxdepth: 2

linear_unmixing
create_a_custom_digital_device_twin
create_custom_tissues
linear_unmixing
minimal_optical_simulation
msot_invision_simulation
perform_image_reconstruction
perform_iterative_qPAI_reconstruction
create_custom_tissues
segmentation_loader
minimal_optical_simulation
perform_image_reconstruction
optical_and_acoustic_simulation
Loading

0 comments on commit 69b1a9d

Please sign in to comment.