Commit graph

916 commits

Author SHA1 Message Date
Dan Short
1de3d9ddf9 Write a test for a serialized source
Heavily based off of the existing custom source test.
Creates a simple class that can be deserialized from XML as use a
serialized XML representation to provide the energy value in the source.
Builds the source and runs the model in the test routine.
2020-07-31 17:32:50 +01:00
Miriam
979317f614 Added surfaces to the reordering of pandas dataframe 2020-07-19 20:52:25 +00:00
Miriam
b903775c46 Ordered the pandas dataframe
In the get_pandas_dataframe function of SurfaceMGXS, I removed all by_nuclide and micro options.
I also ordered the dataframe so that results would be ordered reliably.
This was necessary for tests to pass. Since the domain object is a little different for current than for the other classes,
I had to treat the reorder uniquely for the SurfaceMGXS class because of the presence of the mesh surface filter.
While other classes assume all meshes have a x, y, and z component, regardless of the dimension, this is not true in SurfaceMGXS. Therefore, I added an if statement for each dimension.
2020-07-19 18:10:23 +00:00
Miriam
1c7e7fe3f1 Test passes after modifying get_pandas_dataframe
Since the inherted get_pandas_dataframe sorted values by x, y, z, and the current has a different labelling system
(doesn't include z if only 2 dimensional, and then also includes x-in, x-out, y-in, y-out, z-in z-out...)
I had to redefine get_pandas_dataframe in the SurfaceMGXS class and remove the sorting.
2020-07-19 14:00:21 +00:00
Miriam
676bcefb1e Finalized check for mesh & made progress on regression test
I had to put domain properties back into the SurfaceMGXS class to perform a checktype on the domain_type.
I updated the regression test mgxs_library_mesh to expect the correct input.
However, now the test fails for a 2-dimensional mesh. In 3D, the Current MGXS fails because it does not contain a 'z' dimension.
Meanwhile, all the other classes contain a 'z' dimension, equal to 1.
I need to figure out why the mesh used by SurfaceMGXS doesn't contain the same information as the other classes, even though it is the same mesh used in all.
2020-07-19 04:40:31 +00:00
Miriam
43456ea2d6 Made Current class consistent with mesh domain type
1) Kept by_nuclide, num_nuclides, and nuclides in the docstrings because when building a mgxs library for all mgxs_types, the variables should be the same accross all classes.
However, I noted that they were unused for a SurfaceMGXS.

2) Removed all code related to nuclides and micro xs since they were unused anyway.

3) Removed the possibility of computing a Current with any domain other than mesh.
Included an error message if a current mgxs object is instantiated with any domain other than mesh.
Since mesh domains and by_nuclide features are uncompatible, an existing message is already raised when mesh and by_nuclide are used together.

4) Changed estimator type to analog.
2020-07-17 22:07:15 +00:00
Miriam
2e706e5088 Updated certain tests to circumvent current MGXS when calling all MGXS_TYPES
These tests had to skip 'current' because current operates only with a mesh domain.
However, these tests impose a material domain. Therefore, they should not be run with current.
2020-07-17 03:37:59 +00:00
Paul Romano
7594e7570c Add (n,gamma) rate to photon tests (should be zero) 2020-07-07 09:44:15 -05:00
Amanda Lund
557385c2bf
Merge pull request #1599 from paulromano/energy-dep-fixes
Two fixes for energy deposition calculations
2020-07-04 18:18:50 -05:00
Paul Romano
28df499464 Update test results that use heating 2020-06-30 23:04:14 -05:00
Paul Romano
5dbe549a78
Merge pull request #1593 from drewejohnson/deplete-with-itertools
Allow depletion without multiprocessing
2020-06-29 10:28:26 -05:00
Andrew Johnson
bfd726d824
Parametrize depletion regression test w/ and w/o multiprocessing 2020-06-25 13:22:36 -04:00
Patrick Shriwise
a4fcf9a210
Merge pull request #1588 from paulromano/py38-attribute-order
Fix failing tests for Python 3.8
2020-06-19 08:08:42 -05:00
Paul Romano
ca10c58c8a Ensure boundary_type is used by keyword in several spots 2020-06-17 22:08:56 -05:00
Paul Romano
d999ce3767 Fix uses of is / == 2020-06-16 22:32:40 -05:00
Patrick Shriwise
59552944f5 Adding a check that material filled cells return an empty result. 2020-05-20 12:46:33 -05:00
Patrick Shriwise
00fffc8590 Updating the cpp driver test to include testing of the new set_temperature behavior. Includes a fix to the dynamic source test to remove the CMake file as well. 2020-05-19 15:42:48 -05:00
Patrick Shriwise
31b2f308b5 Providing the model as a fixture. 2020-05-15 11:49:55 -05:00
Patrick Shriwise
64f6d5ce1f Addressing comments from @paulromano. 2020-05-13 17:05:31 -05:00
Patrick Shriwise
ac39214ce4 More PEP8 updates. 2020-05-12 15:20:32 -05:00
Patrick Shriwise
4bb985ea33 Ensuring an mpi compiler when necessary. 2020-05-12 13:39:24 -05:00
Patrick Shriwise
2c0d54adb4 Adding verbosity to travis make. 2020-05-12 10:26:13 -05:00
Patrick Shriwise
2007ba847e Simplifying tests a bit. Updating results. 2020-05-12 08:46:18 -05:00
Patrick Shriwise
a50c4c15e9 PEP8 changes. 2020-05-11 23:14:08 -05:00
Patrick Shriwise
e2774f1f5d No longer running parallel test, seems unecesssary. 2020-05-11 23:07:30 -05:00
Patrick Shriwise
bd6048bc28 Adding test files for the cpp driver test. 2020-05-11 17:52:28 -05:00
Paul Romano
9b499b4096
Merge pull request #1527 from pshriwise/unstructured_mesh
Unstructured Mesh - Initial implementation
2020-03-31 08:54:56 -05:00
Patrick Shriwise
0e3d58958e Address PR suggestions and comments from @paulromano. 2020-03-30 10:35:33 -05:00
Patrick Shriwise
b32514d7b8 Using clearer variable name for test parameter. 2020-03-27 12:12:06 -05:00
Patrick Shriwise
e2f230263f Generating the test model outside of the class definition. 2020-03-27 12:02:28 -05:00
Patrick Shriwise
1716d35ce5 Removing unused list in test file. 2020-03-27 11:38:39 -05:00
alex-lyons
11807ae1f1 In the test, ensure the globbed statepoint filenames are sorted 2020-03-27 07:48:01 -05:00
alex-lyons
f2bc95afa5 Reduce no of batches for trigger from ~47 to ~13 to try to avoid test failures due to numerical differences in platform libraries 2020-03-27 07:47:59 -05:00
Alex Lyons
bd71ac0588 Update tests/regression_tests/trigger_statepoint_restart/test.py
Co-Authored-By: Paul Romano <paul.k.romano@gmail.com>
2020-03-27 07:47:59 -05:00
alex-lyons
a7e924e545 Fix typos and redundant line 2020-03-27 07:47:57 -05:00
alex-lyons
e98ddf9d8a Model.run now returns last statepoint path rather than k_eff. Updated tests and search. 2020-03-27 07:47:54 -05:00
alex-lyons
1312a1cc63 Obtain last statepoint from a glob of output dir. Reverted regex filter in executor as this is no longer needed 2020-03-27 07:47:49 -05:00
alex-lyons
4c96fc11d0 ensure results are loaded from the last statepoint for testing 2020-03-27 07:47:46 -05:00
alex-lyons
954154fa48 Changed PyAPI model and executor to read correct last statepoint after runs with trigger, including new test case 2020-03-27 07:46:47 -05:00
Patrick Shriwise
72e85dd4fa Updating PyAPITestHarness to allow inputs_true file to be specified. 2020-03-26 17:02:15 -05:00
Patrick Shriwise
c54d3abf1c Adjust expected precision based on estimator. 2020-03-26 14:01:57 -05:00
Patrick Shriwise
7e386ff7ff Updating to new midpoint method. 2020-03-26 13:56:23 -05:00
Patrick Shriwise
2bf9e71574 Updating unstructured mesh test file. 2020-03-25 15:29:39 -05:00
Patrick Shriwise
f4092380ff Correction to test cases. 2020-03-25 03:24:40 -05:00
Patrick Shriwise
895249b6ca Addressing changes from PR review. 2020-03-25 03:21:39 -05:00
Patrick Shriwise
ca7cba57df
Apply @paulromano 's suggestions from code review.
Co-Authored-By: Paul Romano <paul.k.romano@gmail.com>
2020-03-25 03:14:58 -05:00
Paul Romano
d8ef73d037 Make sure boundary_type is passed as a keyword argument 2020-03-23 20:55:01 -05:00
Paul Romano
2160e6b156
Merge pull request #1514 from dryuri92/patch-1
Fix the bug on MGXS mode with Interpolation method
2020-03-23 11:26:49 -05:00
dryuri92
051ebfcff3
remove unused lines 2020-03-23 14:16:05 +03:00
dryuri92
db0d5abbf4
indented to the level
small fixes
2020-03-23 14:14:55 +03:00