mirror of
https://github.com/openmc-dev/openmc.git
synced 2026-07-27 13:45:36 -04:00
Adding check that energy bounds are set
This commit is contained in:
parent
4cd9b585f4
commit
a76bd56ecd
1 changed files with 2 additions and 0 deletions
|
|
@ -192,6 +192,8 @@ class WeightWindows(IDManagerMixin):
|
|||
|
||||
@property
|
||||
def num_energy_bins(self):
|
||||
if self.energy_bounds is None:
|
||||
raise ValueError('Energy bounds are not set')
|
||||
return self.energy_bounds.size - 1
|
||||
|
||||
@property
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue