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

RECONR #118

Open
wants to merge 70 commits into
base: release/v1.3.0
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
70 commits
Select commit Hold shift + click to select a range
149e5be
Doing a little cleanup.
jlconlin Nov 4, 2019
61d48aa
Additional cleanup.
jlconlin Nov 4, 2019
825c9e8
Adding a bunch of tests.
jlconlin Dec 13, 2019
beaa152
Merge branch 'master' into feature/RECONR
jlconlin Dec 16, 2019
49be84c
Updating CMake stuff.
jlconlin Dec 16, 2019
a1eec7a
Removing njoy21::Sequence, it was never used anyway.
jlconlin Dec 16, 2019
a2ac204
Moving cycle function closer to where it is used.
jlconlin Dec 16, 2019
9321fee
Doing some cleanup while trying to understand what is going on.
jlconlin Dec 16, 2019
3e325c7
Adding first of modern stuff.
jlconlin Dec 17, 2019
5383432
Getting NJOY21 to actually call the modern component.
jlconlin Dec 17, 2019
e16fbd5
Getting NJOY21 to create JSON object of lipservice output.
jlconlin Dec 17, 2019
705b008
Adding RECONR submodule and making it call the module appropriately.
jlconlin Dec 18, 2019
0a070d9
Adding extra JSON argument to pass to modern routines.
jlconlin Dec 19, 2019
c060bce
Now will 'move' JSON argument instead of passing vy value.
jlconlin Dec 24, 2019
d0019b8
Merge branch 'master' into feature/RECONR
jlconlin Mar 26, 2020
a9aa303
Removing variant-adapter.
jlconlin Mar 26, 2020
52bd449
Updating some submodules.
jlconlin Mar 26, 2020
c3bf7a4
First attempt at using FetchContent. Need to update other repositori…
nathangibson14 May 20, 2020
6a7672d
First working FetchContent rendition.
nathangibson14 May 20, 2020
a61a338
Added live/signature/local FetchContent options.
nathangibson14 May 21, 2020
f05d8c2
Added unit testing to new build system
nathangibson14 May 26, 2020
420ab30
Minor update to cmake files
nathangibson14 May 26, 2020
7524d84
Removed legacy build system folders.
nathangibson14 May 26, 2020
797adf3
Updated signature example.
nathangibson14 May 27, 2020
d489d2d
Merge branch 'build/fetchcontent' into feature/RECONR
nathangibson14 Jun 12, 2020
1a8fdc9
Added back RECONR dependency.
nathangibson14 Jun 12, 2020
86456ec
Fixing call to module.
jlconlin Jun 22, 2020
7d1c533
Passing std::ostream to routines.
jlconlin Jun 22, 2020
16eedce
Adding std::cerr to pass to modern routines.
jlconlin Jun 22, 2020
be6bc52
Trying to get timing information.
jlconlin Jul 16, 2020
60f49df
Timing now works.
jlconlin Jul 16, 2020
d372265
CMake shenanigans
jlconlin Aug 12, 2020
2a24916
Removing njoy21 library creation.
jlconlin Aug 12, 2020
49dd6e2
Merge pull request #112 from njoy/feature/no-library
jlconlin Aug 12, 2020
1f255a4
Updating with new header arrangement.
jlconlin Oct 7, 2020
1e482cb
Merge branch 'feature/no-library' into feature/RECONR
jlconlin Oct 7, 2020
1b1fb26
Trying to update dependencies.
jlconlin Oct 7, 2020
55d7581
Merge branch 'party' into feature/RECONR
jlconlin Oct 30, 2020
1bb91b9
Removing some obsolete cmake files.
jlconlin Oct 30, 2020
3424563
Trying to figure this out.
jlconlin Oct 30, 2020
668e8c5
Adding RECONR include.
jlconlin Nov 2, 2020
db248c0
Merge branch 'release/v1.2.1' into feature/RECONR
jlconlin Nov 3, 2020
12e5a52
Adding Log as a dependency.
jlconlin Nov 4, 2020
1e5dd98
Updating ENDFtk fetchcontent.
jlconlin Dec 2, 2020
cba4bae
Merge branch 'release/v1.3.0' into feature/RECONR
jlconlin Dec 16, 2020
01ba303
Making CommandLine test compile faster.
jlconlin Dec 16, 2020
c988cf3
Updating RECONR branch to master.
jlconlin Jan 13, 2021
1c3f9f7
Merge branch 'release/v1.3.0' into feature/RECONR
jlconlin Jan 22, 2021
2c5c508
Merge branch 'release/v1.3.0' into feature/RECONR
jlconlin Jan 22, 2021
d3ae2ee
Updating inputs because modern RECONR can't do binary tapes.
jlconlin Jan 22, 2021
e116797
Merge branch 'release/v1.3.0' into feature/RECONR
jlconlin Jan 22, 2021
197cf68
Removing the first set of regression tests.
jlconlin Jan 22, 2021
2c97e87
Removing more regression tests.
jlconlin Jan 23, 2021
5e337fd
Doing something.
jlconlin Feb 8, 2021
6dc3cbc
Updating resonanceReconstuction commit hash.
jlconlin Feb 8, 2021
83926e6
Fixing a few typos on input decks.
jlconlin Feb 16, 2021
5109d9e
Adding modern::Sequence test.
jlconlin Feb 17, 2021
da3f194
Fixing Driver test with modern RECONR.
jlconlin Feb 17, 2021
09b06b6
Adding some error messages.
jlconlin Feb 18, 2021
d0f1876
Trying to sync input file.
jlconlin Mar 5, 2021
66f52aa
Removing offset.
jlconlin Mar 5, 2021
83f31c5
Fixing an error in Test30 input.
jlconlin Mar 15, 2021
86f0286
Adding some notes about what regression tests are being deleted.
jlconlin Mar 15, 2021
c760b09
Fixing error in input for Test35 with modern RECONR.
jlconlin Mar 15, 2021
009b0fc
Updating regression tests with modern RECONR.
jlconlin Mar 15, 2021
fe85cc9
Ignoring some tests.
jlconlin Mar 16, 2021
fd8cf31
Fixing bugs with Test20.
jlconlin Mar 17, 2021
d601ff9
Ignoring Test30 as modern RECONR can't handle it.
jlconlin Mar 17, 2021
54e82e2
Improving message about ignored tests.
jlconlin Mar 18, 2021
659c40b
Updating RECONR branch.
jlconlin Mar 22, 2021
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
21 changes: 21 additions & 0 deletions .gitmodules
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
[submodule "dependencies/Log"]
path = dependencies/Log
url = https://github.com/njoy/Log.git
[submodule "dependencies/tclap-adapter"]
path = dependencies/tclap-adapter
url = https://github.com/apmccartney/tclap-adapter.git
[submodule "dependencies/catch-adapter"]
path = dependencies/catch-adapter
url = https://github.com/apmccartney/catch-adapter.git
[submodule "dependencies/dimwits"]
path = dependencies/dimwits
url = https://github.com/njoy/DimensionalAnalysis.git
[submodule "dependencies/njoy_c_bindings"]
path = dependencies/njoy_c_bindings
url = https://github.com/njoy/njoy_c_bindings.git
[submodule "dependencies/ENDFtk"]
path = dependencies/ENDFtk
url = https://github.com/njoy/ENDFtk.git
[submodule "dependencies/lipservice"]
path = dependencies/lipservice
url = https://github.com/njoy/lipservice.git
2 changes: 2 additions & 0 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -62,6 +62,7 @@ target_include_directories( njoy21_library
)
target_link_libraries( njoy21_library
INTERFACE leapr
INTERFACE RECONR
INTERFACE ENDFtk
INTERFACE dimwits
INTERFACE lipservice
Expand Down Expand Up @@ -100,5 +101,6 @@ if( CMAKE_SOURCE_DIR STREQUAL CMAKE_CURRENT_SOURCE_DIR )
message( STATUS "Adding integral testing" )
enable_testing()
add_subdirectory( tests )
configure_file( cmake/CTestCustom.cmake ${CMAKE_BINARY_DIR} )

endif()
14 changes: 14 additions & 0 deletions ReleaseNotes.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,20 @@ See [Pull Request #144](https://github.com/njoy/NJOY21/pull/144)
### Regression Tests
There are a number of [regression tests](https://www.njoy21.io/NJOY2016/testDescription.html) with NJOY21. These are the same as used in NJOY2016. Some of them are no longer valid with NJOY21. With NJOY21, features that are not included in ENDF/B-VII.0 or later, are not going to be supported in NJOY21. There are some regression tests that are no going to be supported in NJOY21. They are:

- [Test01](https://www.njoy21.io/NJOY2016/testDescription.html#test-problem-1)
Uses ENDF/B-V tape.
- [Test02](https://www.njoy21.io/NJOY2016/testDescription.html#test-problem-2)
Uses ENDF/B-IV tape.
- [Test03](https://www.njoy21.io/NJOY2016/testDescription.html#test-problem-3)
- [Test04](https://www.njoy21.io/NJOY2016/testDescription.html#test-problem-4)
Uses ENDF/B-V tape.
- [Test05](https://www.njoy21.io/NJOY2016/testDescription.html#test-problem-5)
Uses ENDF/B-V tape.
- [Test06](https://www.njoy21.io/NJOY2016/testDescription.html#test-problem-6)
Uses ENDF/B-V tape.
- [Test07](https://www.njoy21.io/NJOY2016/testDescription.html#test-problem-7)
Uses ENDF/B-V tape.

## [NJOY21 1.2.2](https://github.com/njoy/NJOY21/pull/142)
- Updating Legacy NJOY to NJOY2016.61. See [release 2016.61](https://github.com/njoy/NJOY2016/releases/tag/2016.61) for more information
- Adding additional regression tests.
Expand Down
11 changes: 11 additions & 0 deletions cmake/CTestCustom.cmake
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
# These tests are ignored. Remove them from here when that feature of NJOY21
# gets implemented
set(CTEST_CUSTOM_TESTS_IGNORE
$CTEST_CUSTOM_TESTS_IGNORE
# Missing capability in RECONR https://github.com/njoy/RECONR/issues/14
Test30
# Poor B-10 evaluation
Test45
# Missing capability in RECONR https://github.com/njoy/RECONR/issues/14
Test60
)
17 changes: 15 additions & 2 deletions cmake/develop_dependencies.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,18 @@ include( FetchContent )
# Declare project dependencies
#######################################################################

FetchContent_Declare( nlohmann_json
GIT_REPOSITORY https://github.com/nlohmann/json
GIT_TAG v3.7.3
)
set(JSON_BuildTests OFF CACHE INTERNAL "")

FetchContent_Declare( RECONR
GIT_REPOSITORY https://github.com/njoy/RECONR
GIT_TAG origin/master
GIT_SHALLOW TRUE
)

FetchContent_Declare( leapr
GIT_REPOSITORY https://github.com/njoy/leapr
GIT_TAG origin/master
Expand All @@ -13,7 +25,7 @@ FetchContent_Declare( leapr

FetchContent_Declare( ENDFtk
GIT_REPOSITORY https://github.com/njoy/ENDFtk
GIT_TAG origin/develop
GIT_TAG origin/release
GIT_SHALLOW TRUE
)

Expand All @@ -31,7 +43,7 @@ FetchContent_Declare( lipservice

FetchContent_Declare( njoy
GIT_REPOSITORY http://github.com/njoy/NJOY2016
GIT_TAG 2016.61
GIT_TAG origin/develop
)

FetchContent_Declare( njoy_c_bindings
Expand Down Expand Up @@ -64,6 +76,7 @@ FetchContent_Declare( utility

FetchContent_MakeAvailable(
leapr
RECONR
ENDFtk
dimwits
lipservice
Expand Down
69 changes: 62 additions & 7 deletions cmake/release_dependencies.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -5,16 +5,22 @@ include( FetchContent )
# Declare project dependencies
#######################################################################

FetchContent_Declare( leapr
GIT_REPOSITORY https://github.com/njoy/leapr
GIT_TAG ff2a1fa90f28e29b5eda100428c35150d1ff89f7
)

FetchContent_Declare( catch-adapter
GIT_REPOSITORY https://github.com/njoy/catch-adapter
GIT_TAG fb84b82ebf7a4789aa43cea560680cf745c6ee4f
)

FetchContent_Declare( eigen
GIT_REPOSITORY https://gitlab.com/libeigen/eigen.git
GIT_TAG dc252fbf00079ccab57948a164b1421703fe4361 # tag: 3.3.8
)
set(BUILD_TESTING OFF CACHE BOOL OFF )

FetchContent_Declare( constants
GIT_REPOSITORY https://github.com/njoy/constants
GIT_TAG c113d6517a8946e0f4280ab5c38de50139df99d0
)

FetchContent_Declare( dimwits
GIT_REPOSITORY https://github.com/njoy/DimensionalAnalysis
GIT_TAG acd794d373c8740a788f5c9d58a6eb8ba4d9861a
Expand All @@ -25,9 +31,19 @@ FetchContent_Declare( disco
GIT_TAG a1a7ddb2c0f69465524d8640ee29988b714a881e
)

FetchContent_Declare( eigen
GIT_REPOSITORY https://gitlab.com/libeigen/eigen.git
GIT_TAG dc252fbf00079ccab57948a164b1421703fe4361 # tag: 3.3.8
)

FetchContent_Declare( elementary
GIT_REPOSITORY https://github.com/njoy/elementary
GIT_TAG 97224cd76b92f174567fdd9259d3b7d8b41ccfae # tag: v0.2.2
)

FetchContent_Declare( ENDFtk
GIT_REPOSITORY https://github.com/njoy/ENDFtk
GIT_TAG d72711722a269919321e3f3df8a8b0cfe23ba6c7
GIT_TAG 65f70e1b771a167b912b2a091f80b891b1b64d27
)

FetchContent_Declare( hana-adapter
Expand All @@ -40,6 +56,16 @@ FetchContent_Declare( header-utilities
GIT_TAG cc2610fee15e255c151e8e22aca1e8b3d1a96b39
)

FetchContent_Declare( interpolation
GIT_REPOSITORY https://github.com/njoy/interpolation
GIT_TAG 2a76934a148bf379ab594f6cdd2cdf4c8c28e447
)

FetchContent_Declare( leapr
GIT_REPOSITORY https://github.com/njoy/leapr
GIT_TAG 645eec428aaece34ab9eae287419e91c8fd7362f
)

FetchContent_Declare( lipservice
GIT_REPOSITORY https://github.com/njoy/lipservice
GIT_TAG 1efa5e9452384a7bfc278fde57979c4d91e312c0
Expand All @@ -64,12 +90,28 @@ FetchContent_Declare( nlohmann_json
GIT_REPOSITORY https://github.com/nlohmann/json
GIT_TAG e7b3b40b5a95bc74b9a7f662830a27c49ffc01b4 # tag: v3.7.3
)
set(JSON_BuildTests OFF CACHE INTERNAL "")

FetchContent_Declare( pybind11
GIT_REPOSITORY https://github.com/pybind/pybind11
GIT_TAG f1abf5d9159b805674197f6bc443592e631c9130 # tag: v2.6.1
)

FetchContent_Declare( range-v3-adapter
GIT_REPOSITORY https://github.com/njoy/range-v3-adapter
GIT_TAG 252679d4737c8f755d87c0e1eed6c37394a2ec59
)

FetchContent_Declare( RECONR
GIT_REPOSITORY https://github.com/njoy/RECONR
GIT_TAG fdc00f11b99c2edccfb7a680b0af9609faefcb3b
)

FetchContent_Declare( resonanceReconstruction
GIT_REPOSITORY https://github.com/njoy/resonanceReconstruction
GIT_TAG d54062b991c73e675f5afd2ba0db6c76eb2c2d9c
)

FetchContent_Declare( spdlog
GIT_REPOSITORY https://github.com/gabime/spdlog
GIT_TAG a51b4856377a71f81b6d74b9af459305c4c644f8
Expand All @@ -80,6 +122,11 @@ FetchContent_Declare( tclap-adapter
GIT_TAG 2642a0f6913c431608c7cd2c61607cb2d775d5b9
)

FetchContent_Declare( twig
GIT_REPOSITORY https://github.com/njoy/twig
GIT_TAG e209d801a1dc99644ee48e9caaf0afb07ef982ff
)

FetchContent_Declare( utility
GIT_REPOSITORY https://github.com/njoy/utility
GIT_TAG 4e72b708d153450bdbc7fc2b45651d71f9a183dc
Expand All @@ -90,20 +137,28 @@ FetchContent_Declare( utility
#######################################################################

FetchContent_MakeAvailable(
leapr
catch-adapter
constants
dimwits
disco
eigen
elementary
ENDFtk
hana-adapter
header-utilities
interpolation
leapr
lipservice
Log
njoy
njoy_c_bindings
nlohmann_json
pybind11
range-v3-adapter
RECONR
resonanceReconstruction
spdlog
tclap-adapter
twig
utility
)
1 change: 1 addition & 0 deletions cmake/unit_testing.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -15,3 +15,4 @@ add_subdirectory( src/njoy21/Driver/test )
add_subdirectory( src/njoy21/Version/test )
add_subdirectory( src/njoy21/io/Manager/test )
add_subdirectory( src/njoy21/legacy/Sequence/test )
add_subdirectory( src/njoy21/modern/Sequence/test )
1 change: 1 addition & 0 deletions src/njoy21.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@
#pragma GCC diagnostic pop

#include "njoy_c.h"
#include "RECONR.hpp"
#include "leapr.hpp"

namespace njoy{
Expand Down
14 changes: 13 additions & 1 deletion src/njoy21/CommandLine/test/CommandLine.test.cpp
Original file line number Diff line number Diff line change
@@ -1,7 +1,19 @@
#define CATCH_CONFIG_MAIN
#include "catch.hpp"

#include "njoy21.hpp"
#include "Log.hpp"

namespace njoy{
namespace njoy21{

struct CommandLine;

#include "njoy21/Version.hpp"

} // namespace njoy21
} // namespace njoy

#include "njoy21/CommandLine.hpp"

using namespace njoy::njoy21;

Expand Down
2 changes: 1 addition & 1 deletion src/njoy21/Driver/Factory/src/setupLegacyDirectory.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ static Directory setupLegacyDirectory( CommandLine& commandLine ){
"GASPR", "HEATR", "GROUPR", "VIEWR", "MIXR", "DTFR",
"THERMR", "RESXSR", "MATXSR", "GAMINR", "PLOTR",
"COVR", "WIMSR", "POWR", "CCCCR", "ERRORR" } ):
Directory( { "MODER", "RECONR", "BROADR", "PURR", "UNRESR", "ACER",
Directory( { "MODER", "BROADR", "PURR", "UNRESR", "ACER",
"GASPR", "HEATR", "GROUPR", "VIEWR", "MIXR", "DTFR",
"THERMR", "LEAPR", "RESXSR", "MATXSR", "GAMINR", "PLOTR",
"COVR", "WIMSR", "POWR", "CCCCR", "ERRORR" } );
Expand Down
2 changes: 1 addition & 1 deletion src/njoy21/Driver/Factory/src/setupModernDirectory.hpp
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
static Directory setupModernDirectory( CommandLine& commandLine ){
return ( commandLine.legacySwitch ) ?
Directory() :
Directory( { "LEAPR" } );
Directory( { "RECONR", "LEAPR" } );
}
4 changes: 1 addition & 3 deletions src/njoy21/Driver/test/resources/input.njoy
Original file line number Diff line number Diff line change
@@ -1,11 +1,9 @@
moder
20 -30 /
reconr
-30 -31 /
20 31 /
'automated processing using ndvv.njoy.process see *log files' /
2631 0 0 /
0.001 0.0 0.01 5.000000000000004e-08 /
0 /
moder
-31 21 /
stop
9 changes: 5 additions & 4 deletions src/njoy21/io/Manager.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -15,18 +15,19 @@ class Manager {
inputStream( std::move(input) ),
outputPath( std::move(outputPath) ),
errorPath( std::move(errorPath) ),
legacyBuffer( utility::stream::TemporaryFileStream() ){}
legacyBuffer( utility::stream::TemporaryFileStream() )
{}

public:

#include "njoy21/io/Manager/Builder.hpp"
#include "njoy21/io/Manager/FileGuard.hpp"
#include "njoy21/io/Manager/Builder.hpp"
#include "njoy21/io/Manager/FileGuard.hpp"


lipservice::iRecordStream< char >&
input(){ return this->inputStream; }

#include "njoy21/io/Manager/src/output.hpp"
#include "njoy21/io/Manager/src/output.hpp"

std::ostream& buffer(){ return this->legacyBuffer; }

Expand Down
2 changes: 0 additions & 2 deletions src/njoy21/legacy.hpp
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
namespace legacy {

#include "njoy21/legacy/Sequence.hpp"

}
2 changes: 2 additions & 0 deletions src/njoy21/legacy/Sequence/Factory/src/callOperator.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,8 @@ operator()( std::string& label ){
return std::make_unique< Sequence >(
Sequence( manager, std::move( sequence ) ) );
} catch ( std::exception& e ){
Log::info( "Error while calling the legacy::Sequence::Factory" );
Log::info( "\t{}", e.what() );
input.rdbuf( readBuffer );
throw e;
}
Expand Down
13 changes: 9 additions & 4 deletions src/njoy21/legacy/Sequence/routines.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -3,17 +3,22 @@ static void ignore( T&& ){}

#define DEFINE_ROUTINE( MODULE ) \
struct MODULE : public interface::Routine { \
template< typename Char > \
MODULE( lipservice::iRecordStream< Char >& stream ): \
using Stream = lipservice::iRecordStream< char >; \
MODULE( lipservice::iRecordStream< char >& stream ): \
interface::Routine( #MODULE ) \
{ \
lipservice::MODULE command( stream ); \
ignore(command); \
} \
void operator()( std::ostream&, std::ostream&, const nlohmann::json& ){ \
njoy_c_##MODULE(); \
try { \
njoy_c_##MODULE(); \
} catch( std::exception& e ){ \
Log::info( "Trouble running legacy routine: {}", #MODULE ); \
Log::info( "{}", e.what() ); \
throw e; \
} \
} \
virtual std::string name(){ return #MODULE; } \
};

DEFINE_ROUTINE( MODER )
Expand Down
Loading