Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

API DepletionReader export to Matlab file #257

Merged
merged 6 commits into from Dec 26, 2018

Conversation

drewejohnson
Copy link
Collaborator

Utilizes scipy.io.savemat to take contents of the reader and export them to a binary .mat file. This can be loaded into MATLAB, and in many cases is faster and more successful than reading in the text file.
The method supports converting variables back to their original SERPENT_STYLE names or not, and optionally saving metadata as well.

Added unit tests that cover three cases:

  • Reconvert variable names back and write metadata

  • Reconvert variable names but don't write metadata

  • Don't convert variable names but do write metadata

  • PR fits the project scope

  • Code to be committed is DRY and matches the code style of the project

Andrew Johnson added 3 commits December 20, 2018 16:33
Use scipy.io.savemat to save material data and, optionally,
metadata to a file that can be loaded into matlab.
Supports the ability to deconvert variable names back into their
original form, or a mixedCase style, MAT_fuel_ING_TOX or
fuel_ingTox.

The intent is to eventually integrate a CLI tool for
converting.
DepletionReader.saveAsMatlab now respects the metadata
flag, and converts accordingly
Tests cover options to save metadata or not and to
reconvert variable names or not
@drewejohnson drewejohnson added API - Compatible Changes to our API that require no user actions Exporting Items pertaining to exporting to other data types labels Dec 21, 2018
@drewejohnson drewejohnson added this to Review in Main Dec 21, 2018
@drewejohnson drewejohnson merged commit a9b1a73 into CORE-GATECH-GROUP:develop Dec 26, 2018
@drewejohnson drewejohnson deleted the dep-converter branch January 20, 2019 20:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
API - Compatible Changes to our API that require no user actions Exporting Items pertaining to exporting to other data types
Projects
Main
Review
Development

Successfully merging this pull request may close these issues.

None yet

2 participants