Skip to main content

Converts CAD files to a DAGMC h5m file

Project description

CI with install

Upload Python Package


A minimal package that uses CadQuery functionality to convert Cad geometry to DAGMC h5m files

This particular method of producing DAGMC compatible h5m files from CAD geometry is intended to convert STP files or CadQuery objects to h5m file.

One unique feature of this package is the ability to combine STP files with CadQuery objects. This allows for the addition of parametric geometry to static geometry.

Install (Conda)

Creates a new empty Conda environment

conda create --name new_env python=3.9

Installs cad_to_dagmc and dependencies

conda install -c fusion-energy -c cadquery -c conda-forge cad_to_dagmc

Install (Mamba)

Creates a new empty Conda environment

conda create --name new_env python=3.9

Installs Mamba

conda install -c conda-forge mamba

Installs cad_to_dagmc and dependencies

mamba install -c fusion-energy -c cadquery -c conda-forge cad_to_dagmc

Install (Conda + pip)

You will need to install some dependencies that are not available via PyPi.

conda install -c conda-forge mamba
mamba install -c conda-forge moab
mamba install -c cadquery -c conda-forge cadquery=master

Then you can install the cad_to_dagmc package with pip

pip install cad_to_dagmc

Usage

To use the h5m geometry you will need a transport code with DAGMC enabled such as OpenMC. Just to note that currently the conda install for CadQuery and OpenMC can't be installed in the same conda environment. A work around for this is to create the h5m geometry in one conda environment and simulate with OpenMC in another conda environment.

For examples see the examples folder

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

cad_to_dagmc-0.1.0.tar.gz (411.9 kB view hashes)

Uploaded Source

Built Distribution

cad_to_dagmc-0.1.0-py3-none-any.whl (5.8 kB view hashes)

Uploaded Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page