Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/test_package.yml
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ jobs:

- name: Test download chain files scripts exist
run: |
download_endf_chain --help
download_chain --help

- name: Test other scripts exist
run: |
Expand Down
23 changes: 12 additions & 11 deletions .github/workflows/test_processing.yml
Original file line number Diff line number Diff line change
Expand Up @@ -112,28 +112,29 @@ jobs:
download_tendl -r 2019
download_tendl -r 2021

- name: test default download_endf_chain
if: contains(steps.changed-files-specific.outputs.modified_files, 'src/openmc_data/download/download_endf_chain.py')
- name: test default download_chain
if: contains(steps.changed-files-specific.outputs.modified_files, 'src/openmc_data/download/download_chain.py')
run: |
echo "download_endf_chain.py file has been modified."
download_endf_chain -r b7.1 -b None
download_endf_chain -r b8.0 -b None
download_endf_chain -r b7.1 -b SFR
download_endf_chain -r b8.0 -b SFR
download_endf_chain -r b7.1 -b PWR
download_endf_chain -r b8.0 -b PWR
echo "download_chain.py file has been modified."
download_chain -l endf -r b7.1 -b None
download_chain -l endf -r b8.0 -b None
download_chain -l endf -r b7.1 -b SFR
download_chain -l endf -r b8.0 -b SFR
download_chain -l endf -r b7.1 -b PWR
download_chain -l endf -r b8.0 -b PWR
download_chain -l endf -r b8.0 -b PWR

- name: test default add_branching_ratios
if: contains(steps.changed-files-specific.outputs.modified_files, 'src/openmc_data/depletion/add_branching_ratios.py')
run: |
echo "add_branching_ratios.py file has been modified."
download_endf_chain -r b8.0
download_chain -l endf -r b8.0
add_branching_ratios -i chain-endf-b8.0.xml -o chain_endf_b8.0_sfr.xml -b sfr
add_branching_ratios -i chain-endf-b8.0.xml -o chain_endf_b8.0_pwr.xml -b pwr

- name: test default reduce_chain
if: contains(steps.changed-files-specific.outputs.modified_files, 'src/openmc_data/depletion/reduce_chain.py')
run: |
echo "reduce_chain.py file has been modified."
download_endf_chain -r b8.0
download_chain -l endf -r b8.0
reduce_chain -i chain-endf-b8.0.xml -o chain_endf_b8.0_sfr.xml -hl 1e15
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -114,7 +114,7 @@ A few categories of scripts are available:

| Script name | Library | Release | Branching options|
|-|-|-|-|
|download_endf_chain | ENDF/B | VII.1<br>VIII.0 | None<br>SFR<br>PWR
|download_chain | ENDF/B<br><br><br>TENDL | VII.1<br>VIII.0<br><br>2019 | None<br>SFR<br>PWR<br><br>FNS |

<!-- | Sctipt name | Library | Release | Download available | Download ENDF files and generates XML chain files |
|-|-|-|-|-|
Expand Down
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -77,4 +77,4 @@ reduce_chain = "openmc_data.depletion.reduce_chain:main"

download_endf = "openmc_data.download.download_endf:main"
download_tendl = "openmc_data.download.download_tendl:main"
download_endf_chain = "openmc_data.download.download_endf_chain:main"
download_chain = "openmc_data.download.download_chain:main"
Original file line number Diff line number Diff line change
Expand Up @@ -37,20 +37,30 @@ class CustomFormatter(
parser.add_argument(
"-r",
"--release",
choices=["b7.1", "b8.0"],
default="b8.0",
choices=["b7.1", "b8.0", "2019"],
default="2019",
help="The nuclear data library release version. The currently supported "
"options are b7.1 and b8.0.",
)
parser.add_argument(
"-l",
"--library",
choices=["endf", "tendl"],
default="tendl",
help="The nuclear data library. The currently supported options are endf and tendl",
)
parser.add_argument(
"-b",
"--branching_ratios",
choices=["None", "SFR", "PWR", "FNS"],
default="FNS",
help="The nuclear data library release version. The currently supported "
"options are b7.1 and b8.0 with branching ratio options of None, SFR "
"(sodium fast reactor), PWR (pressurized water reactor) or FNS "
"(fusion neutron source)",
"options are endf b7.1 and b8.0 with branching ratio options of None, "
"SFR (sodium fast reactor), PWR (pressurized water reactor) or tendl "
"2019 with FNS (fusion neutron source) branching ratio. The tendl "
"chains are processed with neutron induced fission yields from"
"ENDF/B-VIII.0. There is an option to use JEFF 3.3 if you generate"
"your own chain file with the generate_tendl_chain command line tool.",
)

parser.set_defaults()
Expand All @@ -59,11 +69,10 @@ class CustomFormatter(

def main():

library_name = 'endf'
details = all_chain_release_details[library_name][args.release][args.branching_ratios]["chain"]
details = all_chain_release_details[args.library][args.release][args.branching_ratios]["chain"]

if args.filename is None:
args.filename = Path("-".join(["chain", library_name, args.release])+".xml")
args.filename = Path("-".join(["chain", args.library, args.release])+".xml")
print(f'Using default filename {args.filename}')

download(
Expand Down
4 changes: 4 additions & 0 deletions src/openmc_data/urls_xml.py
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,10 @@
"url": "https://github.com/openmc-data-storage/openmc_data/raw/main/src/openmc_data/depletion/chain_endf_b8.0_pwr.xml"
}
},
}
},
"tendl": {
"2019": {
"FNS": {
"chain": {
"url": "https://github.com/jbae11/openmc_activator/raw/refs/heads/main/fns_spectrum.chain.xml"
Expand Down
Loading