Skip to content

Commit

Permalink
Merge pull request #31 from fusion-energy/develop
Browse files Browse the repository at this point in the history
version release updates
  • Loading branch information
shimwell authored Jan 9, 2023
2 parents cc7a882 + 9138e6a commit 45b2cb4
Show file tree
Hide file tree
Showing 20 changed files with 58 additions and 63 deletions.
4 changes: 2 additions & 2 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ version: 2.1
jobs:
build:
docker:
- image: continuumio/miniconda3:4.9.2
- image: continuumio/miniconda3:4.12.0

working_directory: ~/repo

Expand All @@ -18,7 +18,7 @@ jobs:
- run:
name: install
command: |
conda install -c conda-forge openmc==0.13.0
conda install -c conda-forge openmc==0.13.2
pip install .[density,tests]
# run tests!
Expand Down
48 changes: 45 additions & 3 deletions pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,10 +1,52 @@
[build-system]
requires = [
"setuptools >= 45",
"setuptools >= 65.4.0",
"wheel",
"setuptools_scm[toml] >= 6.2",
"setuptools_scm[toml] >= 7.0.5",
]
build-backend = "setuptools.build_meta"

[project]
name = "neutronics_material_maker"
authors = [
{ name="Jonathan Shimwell", email="[email protected]" },
]
license = {file = "LICENSE.txt"}
description = "A tool for making reproducible materials and standardizing use across several neutronics codes"
readme = "README.md"
requires-python = ">=3.8"
keywords = ["material", "library", "database", "serpent", "mcnp", "openmc", "fispact"]
classifiers = [
"Programming Language :: Python :: 3",
"License :: OSI Approved :: MIT License",
"Operating System :: OS Independent",
]
dependencies = [
"asteval>=0.9.20",
]
dynamic = ["version"]


[tool.setuptools_scm]
write_to = "neutronics_material_maker/_version.py"
write_to = "src/_version.py"


[project.optional-dependencies]
density = [
"coolprop"
]
tests = [
"pytest",
"pytest-cov"
]
docs = [
"sphinx",
"sphinx_autodoc_typehints",
]

[project.urls]
"Homepage" = "https://github.com/fusion-energy/neutronics_material_maker"
"Bug Tracker" = "https://github.com/fusion-energy/neutronics_material_maker/issues"

[tool.setuptools]
package-dir = {"" = "src"}
46 changes: 0 additions & 46 deletions setup.cfg

This file was deleted.

4 changes: 0 additions & 4 deletions setup.py

This file was deleted.

File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -14,9 +14,10 @@
},
"SiC": {
"chemical_equation": "SiC",
"density": 3.0,
"density": 3.21,
"density_unit": "g/cm3",
"percent_type": "ao"
"percent_type": "ao",
"comment": "https://www.sciencedirect.com/topics/materials-science/silicon-carbide"
},
"eurofer": {
"elements": {
Expand Down Expand Up @@ -103,18 +104,20 @@
"S": 5e-06,
"Si": 2e-05
},
"density": 19.0,
"density": 19.3,
"density_unit": "g/cm3",
"comment": "neutronics handbook",
"percent_type": "ao"
"percent_type": "ao",
"comment": "https://physics.nist.gov/cgi-bin/Star/compos.pl?mode=text&matno=074"
},
"tungsten": {
"elements": {
"W": 1.0
},
"density": 19.2,
"density": 19.3,
"density_unit": "g/cm3",
"percent_type": "ao"
"percent_type": "ao",
"comment": "https://physics.nist.gov/cgi-bin/Star/compos.pl?mode=text&matno=074"
},
"P91": {
"elements": {
Expand Down
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -496,7 +496,7 @@ def make_fispact_material(mat) -> str:
for (
isotope,
atoms_barn_cm,
) in mat.openmc_material.get_nuclide_atom_densities().values():
) in mat.openmc_material.get_nuclide_atom_densities().items():
atoms_cm3 = atoms_barn_cm * 1.0e24
atoms = mat.volume_in_cm3 * atoms_cm3
mat_card.append(isotope + " " + "{:.12E}".format(atoms))
Expand Down Expand Up @@ -618,7 +618,7 @@ def make_shift_material(mat) -> str:
# shift units in atoms / barn-cm
for nuclide, atom_dens in mat.openmc_material.get_nuclide_atom_densities().items():
zaid += " " + isotope_to_zaid(nuclide)
nd_ += " " + f"{atom_dens[1]:.{mat.decimal_places}e}"
nd_ += " " + f"{atom_dens:.{mat.decimal_places}e}"

mat_card.extend([zaid, nd_])

Expand Down

0 comments on commit 45b2cb4

Please sign in to comment.