Skip to content

Commit

Permalink
update
Browse files Browse the repository at this point in the history
  • Loading branch information
Fiorito Luca committed Jun 10, 2021
1 parent ba739df commit 56a30ee
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 3 deletions.
10 changes: 8 additions & 2 deletions sandy/core/endf6.py
Original file line number Diff line number Diff line change
Expand Up @@ -783,6 +783,7 @@ def get_ace(self,
temperature,
njoy=None,
verbose=False,
pendf=None,
**kwargs,
):
"""
Expand All @@ -793,7 +794,7 @@ def get_ace(self,
temperature : `float`
temperature of the cross sections in K.
njoy : `str`, optional, default is `None`
NJOY executable, if `None` serahc in the system path.
NJOY executable, if `None` search in the system path.
verbose : TYPE, optional, default is `False`
flag to print NJOY input file to screen before running the
executable.
Expand All @@ -813,11 +814,16 @@ def get_ace(self,
{'ace': '1001.07c', 'xsdir': '1001.07c.xsd'}
"""
outs = {}
pendftape = None
with TemporaryDirectory() as td:
endf6file = os.path.join(td, "endf6_file")
self.to_file(endf6file)
if pendf:
pendftape = os.path.join(td, "pendf_file")
pendf.to_file(pendftape)
text, inputs, outputs = sandy.njoy.process(
endf6file,
pendftape=pendftape,
wdir=".",
keep_pendf=False,
exe=njoy,
Expand Down Expand Up @@ -853,7 +859,7 @@ def get_pendf(self,
temperature of the cross sections in K.
If not given, stop the processing after RECONR (before BROADR).
njoy : `str`, optional, default is `None`
NJOY executable, if `None` serahc in the system path.
NJOY executable, if `None` search in the system path.
to_file : `bool`, optional, default is `False`
flag to write processed PENDF data to file.
The name of the PENDF file is defined by an internal routine.
Expand Down
3 changes: 2 additions & 1 deletion sandy/njoy.py
Original file line number Diff line number Diff line change
Expand Up @@ -708,7 +708,8 @@ def process(
Parameters
----------
pendftape : `str`, optional, default is `None`
skip module reconr and use this PENDF file
name (with absolute of relative path) of a pendf file.
If given, skip module reconr and use this PENDF file, else run reconr
kermas : iterable of `int`, optional, default is
`[302, 303, 304, 318, 402, 442, 443, 444, 445, 446, 447]`
MT numbers for partial kermas to pass to heatr.
Expand Down

0 comments on commit 56a30ee

Please sign in to comment.