Skip to content

Commit

Permalink
added pip option
Browse files Browse the repository at this point in the history
  • Loading branch information
shimwell committed Mar 17, 2024
1 parent 940775d commit 79a8105
Showing 1 changed file with 26 additions and 4 deletions.
30 changes: 26 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -31,14 +31,15 @@ Also checkout these other software projects that also create DAGMC geometry [CAD

# Installation prerequisite

In principle, any Conda/Mamba distribution will work. A few Conda/Mamba options are:
- [Miniforge](https://github.com/conda-forge/miniforge) (recommended as it includes mamba)
- [Anaconda](https://www.anaconda.com/download)
- [Miniconda](https://docs.conda.io/en/latest/miniconda.html)


# Install using Mamba and pip

In principle, installing any Conda/Mamba distribution will work. A few Conda/Mamba options are:
- [Miniforge](https://github.com/conda-forge/miniforge) (recommended as it includes mamba)
- [Anaconda](https://www.anaconda.com/download)
- [Miniconda](https://docs.conda.io/en/latest/miniconda.html)

This example assumes you have installed the Miniforge option or separately have installed Mamba with ```conda install -c conda-forge mamba -y```

Create a new conda environment, I've chosen Python 3.10 here but newer versions are
Expand Down Expand Up @@ -76,6 +77,11 @@ Another option would be to [install OpenMC from source](https://docs.openmc.org/

# Install using Conda and pip

In principle, installing any Conda/Mamba distribution will work. A few Conda/Mamba options are:
- [Miniforge](https://github.com/conda-forge/miniforge) (recommended as it includes mamba)
- [Anaconda](https://www.anaconda.com/download)
- [Miniconda](https://docs.conda.io/en/latest/miniconda.html)

This example uses Conda to install some dependencies that are not available via PyPi.

Create a new conda environment
Expand All @@ -98,6 +104,22 @@ Then you can install the cad_to_dagmc package with ```pip```
pip install cad_to_dagmc
```

# Install using pip

It is possible to avoid the use of conda and installing using pip and compiling from source.

First compile MOAB (and install Pymoab) from source

Then install cadquery and ocp using pip
pip install cadquery-ocp==7.7.2
pip install cadquery==2.4.0

Then you can install the cad_to_dagmc package with ```pip```
```bash
pip install cad_to_dagmc
```


# Usage - with OpenMC

You may also want to install OpenMC with DAGMC to make use of the h5m geometry files produced in simulations. However you could also use other supported particle transport codes such as MCNP, FLUKA and others supported by [DAGMC](https://svalinn.github.io/DAGMC/).
Expand Down

0 comments on commit 79a8105

Please sign in to comment.