satisfying @wbinventors pyapi comments

This commit is contained in:
Adam Nelson 2016-01-09 05:43:28 -05:00
parent ccb15f27ef
commit 08fdb8a91d
4 changed files with 18 additions and 18 deletions

View file

@ -332,7 +332,7 @@ class Material(object):
Parameters
----------
macroscopic : str or openmc.macroscopic.Macroscopic
macroscopic : str or Macroscopic
Macroscopic to add
"""
@ -371,7 +371,7 @@ class Material(object):
Parameters
----------
macroscopic : openmc.macroscopic.Macroscopic
macroscopic : Macroscopic
Macroscopic to remove
"""
@ -622,14 +622,14 @@ class Material(object):
# Create element XML subelements
subelements = self._get_elements_xml(self._elements, distrib=True)
for subelement_ele in subelements:
subelement.append(subelement_ele)
for subsubelement in subelements:
subelement.append(subsubelement)
else:
# Create macroscopic XML subelements
subelement_ele = self._get_macroscopic_xml(self,
self._macroscopic,
distrib=True)
subelement.append(subelement_ele)
subsubelement = self._get_macroscopic_xml(self,
self._macroscopic,
distrib=True)
subelement.append(subsubelement)
if len(self._sab) > 0:
for sab in self._sab:

View file

@ -54,7 +54,7 @@ class EnergyGroups(object):
def __eq__(self, other):
if not isinstance(other, EnergyGroups):
return False
elif (self.group_edges != other.group_edges).all():
elif self.group_edges != other.group_edges:
return False
else:
return True

View file

@ -14,7 +14,7 @@ from openmc.checkvalue import check_type, check_value, check_greater_than, \
check_iterable_type
from openmc.clean_xml import *
# MGXS Representations supported by OpenMC
# Supported incoming particle MGXS angular treatment representations
REPRESENTATIONS = ['isotropic', 'angle']
def ndarray_to_string(arr):
@ -87,7 +87,7 @@ class XSdata(object):
name : str, optional
Name of the mgxs data set.
representation : str
representation : {'isotropic' or 'angle'}
Method used in generating the MGXS (isotropic or angle-dependent flux
weighting). Defaults to 'isotropic'
@ -99,11 +99,11 @@ class XSdata(object):
Separate unique identifier for the xsdata object
kT : float
Temperature (in units of MeV) of this data set.
energy_groups : openmc.mgxs.EnergyGroups
energy_groups : EnergyGroups
Energy group structure
fissionable : boolean
Whether or not this is a fissionable data set.
scatt_type : str
scatt_type : {'legendre', 'histogram', or 'tabular'}
Angular distribution representation (legendre, histogram, or tabular)
order : int
Either the Legendre order, number of bins, or number of points used to
@ -111,9 +111,9 @@ class XSdata(object):
transfer probability.
tabular_legendre : dict
Set how to treat the Legendre scattering kernel (tabular or leave in
Legendre polynomial form). Dict contains two keys: ``enable`` and
``num_points``. ``enable`` is a boolean and ``num_points`` is the
number of points to use, if ``enable`` is True.
Legendre polynomial form). Dict contains two keys: 'enable' and
'num_points'. 'enable' is a boolean and 'num_points' is the
number of points to use, if 'enable' is True.
"""
def __init__(self, name, energy_groups, representation="isotropic"):
@ -247,7 +247,7 @@ class XSdata(object):
@alias.setter
def alias(self, alias):
if alias is not None:
check_type('alias for XSdata', alias, basestring)
check_type('alias', alias, basestring)
self._alias = alias
else:
self._alias = self._name

View file

@ -79,7 +79,7 @@ class SettingsFile(object):
Set whether the calculation should be continuous-energy or multi-group.
Acceptable values are 'continuous-energy' or 'multi-group'
max_order : int
Maximum scattering order to apply globally when in multi-grup mode.
Maximum scattering order to apply globally when in multi-group mode.
ptables : bool
Determine whether probability tables are used.
run_cmfd : bool