Replies: 5 comments 2 replies
-
Argument in favor of function: Argument in favor of property:
Since these operations do not perform computationally expensive operations or have side effects or perform actions, they should be accessed as properties. Therefore, IMO, the property notation is a better fit. |
Beta Was this translation helpful? Give feedback.
-
|
Update: Features added
Install it:python -m pip install montepy==1.0.0a2 |
Beta Was this translation helpful? Give feedback.
-
|
Update: Features Added
Install it:python -m pip install montepy==1.0.0a3or conda install --channel conda-forge/label/alpha montepy |
Beta Was this translation helpful? Give feedback.
-
|
The time is near ⌛👀 |
Beta Was this translation helpful? Give feedback.
-
|
1.0.0 has been shipped! So this thread is now outdated. |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Release
The alpha release of version 1.0.0 is now available on PyPI, and we need alpha testers.
To install this version specifically (in an isolated conda or virtual environment might be a good idea) run:
Changes
This release primarily focuses on redesigning the material interface. For details see the migration guide. Also the updated getting started guide shows how to use a lot of these new features.
The biggest change is that
Materialis no longer a wrapper of dictionary; it now behaves like a list.This will make it a lot easier to do the following with materials:
nlib=80cfor a specific materialmontepy.Nuclide("U-235m1.80c")This will also make it a lot easier to work with MontePy objects in general by:
cell.nuber = 5from having no effect.montepy.Cell("1 0 -2 imp:n=1"). In a lot of cases it's a better idea to do:problem.parse("1 0 -2 imp:n=1").Features Added
Material Interface Changes
Mat redesign #507
montepy.Nuclide("H-1.80c")Improve Isotope Instantiation #505
Material strings can become unruly. #144
Allow querying materials by elements #95
nlib, from a materialAdd support for particle specific libraries and default libraries. #369
montepy.Cell.Material.is_atom_fractionsettableMake
Material.is_atom_fractionsettable #511General Updates
Implement __slots__ to avoid user confusion #508
Make NumberedObjectCollection act like a set #138
Remove duplicate objects without relying on Hashing #63
Improve ab initio DataCard __init__ #88
MCNP_Problem.parseto parse arbitrary MCNP objectImprove ab initio DataCard __init__ #88
Bugs Fixed
Can't make a material from scratch and export it. #512
Support poorly formatted Material definitions #182
Breaking Changes
Material.material_componentsMat redesign #507
Isotopeand changed them toNuclideMCNP_Problem.add_cell_children_to_problemas it is no longer needed.Feedback/ Ask
We ultimately need users to play with these changes in realistic situations, and find things that are broken, or that are not quite right. You can open new issues with this feedback or add them to this thread.
If you find MontePy useful, please give us a star.
Questions
Here are some open questions I have about the design I would like feedback on:
Should
material.valuesandmaterial.nuclidesnot be properties but functions?Does the way of specifying a
montepy.Nuclidemake sense?Does the following ways of searching make sense and behave predictably?
nuclide in materialmaterial.contains()materials.get_containing()Beta Was this translation helpful? Give feedback.
All reactions