Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Broken examples #173

Closed
lewisfish opened this issue Mar 22, 2024 · 1 comment
Closed

Broken examples #173

lewisfish opened this issue Mar 22, 2024 · 1 comment
Assignees

Comments

@lewisfish
Copy link

Hi MCDC team,

I've found the following examples won't run or plot correctly:

  • fixed_source/pulsed_sphere gives the following error:
    mat_iron = mcdc.material(
               ^^^^^^^^^^^^^^
  File "/home/JOSS/MCDC/mcdc/input_.py", line 326, in material
    with h5py.File(dir_name + "/" + nuc_name + ".h5", "r") as f:
                   ~~~~~~~~~^~~~~
TypeError: unsupported operand type(s) for +: 'NoneType' and 'str'
  • fixed_source/inf_pin_ce has the same error as above.
  • fixed_source/slab_ce has the same issue as above. This example could also benefit from more instructions (what is build_xml.py purpose?) and a mention that openmc is a dependency.
  • fixed_source/slab_reed_iqmc is missing a plt.show() or savefig from the process.py file.
  • eigenvalue/2d_c5g7 fails to plot with the following error. I think this is due to the "C" argument to pcolormesh only having 1 dimension
  File "/home/JOSS/MCDC/examples/eigenvalue/2d_c5g7/process.py", line 95, in <module>
    plt.pcolormesh(X, Y, phi_thermal_sd, shading="nearest")
  File "/home/anaconda3/envs/mcdc-env/lib/python3.11/site-packages/matplotlib/pyplot.py", line 3493, in pcolormesh
    __ret = gca().pcolormesh(
            ^^^^^^^^^^^^^^^^^
  File "/home/anaconda3/envs/mcdc-env/lib/python3.11/site-packages/matplotlib/__init__.py", line 1465, in inner
    return func(ax, *map(sanitize_sequence, args), **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/anaconda3/envs/mcdc-env/lib/python3.11/site-packages/matplotlib/axes/_axes.py", line 6292, in pcolormesh
    X, Y, C, shading = self._pcolorargs('pcolormesh', *args,
                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/anaconda3/envs/mcdc-env/lib/python3.11/site-packages/matplotlib/axes/_axes.py", line 5815, in _pcolorargs
    nrows, ncols = C.shape[:2]
    ^^^^^^^^^^^^
ValueError: not enough values to unpack (expected 2, got 1)
  • eigenvalue/slab_kornreich_iqmc is missing a plt.show() or savefig from the process.py file.
  • eigenvalue/smrg7 fails with ERROR: Particle census bank is full
  • c5g7/3d/TDX the default particle number does not resolve to the reference solution.

openjournals/joss-reviews#6415

@jpmorgan98 jpmorgan98 self-assigned this Mar 22, 2024
@jpmorgan98
Copy link
Collaborator

jpmorgan98 commented Mar 22, 2024

The issue with the following examples:

  • fixed_source/pulsed_sphere
  • fixed_source/inf_pin_ce
  • fixed_source/slab_ce

I believe is because the continuous energy data library is not configured. (@ilhamv please confirm). If this is the case due to legal requirements we cannot publish or distribute that data for use outside of our center. I will add a runtime error that will stop the simulation in this case and add notes to the example files themselves. See our docs. Kinda a weird place for an open source software to be but it is what it is

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants