Fixed issue with double subdomain-avg MGXS

This commit is contained in:
wbinventor@gmail.com 2016-01-30 15:06:55 -05:00
parent 1bd815c529
commit fb0e166e1c
2 changed files with 5 additions and 3 deletions

View file

@ -823,7 +823,8 @@ class AggregateFilter(object):
"""
if filter_bin not in self.bins:
if filter_bin not in self.bins and \
filter_bin != self._aggregate_filter.bins:
msg = 'Unable to get the bin index for AggregateFilter since ' \
'"{0}" is not one of the bins'.format(filter_bin)
raise ValueError(msg)

View file

@ -568,8 +568,9 @@ class Library(object):
for domain in self.domains:
for mgxs_type in self.mgxs_types:
mgxs = subdomain_avg_library.get_mgxs(domain, mgxs_type)
avg_mgxs = mgxs.get_subdomain_avg_xs()
subdomain_avg_library.all_mgxs[domain.id][mgxs_type] = avg_mgxs
if mgxs.domain_type == 'distribcell':
avg_mgxs = mgxs.get_subdomain_avg_xs()
subdomain_avg_library.all_mgxs[domain.id][mgxs_type] = avg_mgxs
return subdomain_avg_library