Skip to content

Commit

Permalink
separated multivar and traditional mode frontend classes to simplify …
Browse files Browse the repository at this point in the history
…the mode executive class design
  • Loading branch information
davidalbo committed Dec 28, 2023
1 parent f1a345e commit ce7943a
Show file tree
Hide file tree
Showing 9 changed files with 891 additions and 1,120 deletions.
11 changes: 7 additions & 4 deletions src/tools/core/mode/mode.cc
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,7 @@
// 020 07/06/22 Howard Soh METplus-Internal #19 Rename main to met_main
// 021 06/09/23 Albo Major changes for multivariate mode
// 022 11/02/23 Halley Gotway MET #2724 add OpenMP to convolution
// 023 12/27/23 Albo MET #2745 more unit tests, read data one time, percentile thresholding
//
////////////////////////////////////////////////////////////////////////

Expand All @@ -78,6 +79,7 @@ using namespace std;
#include "string_array.h"
#include "mode_usage.h"
#include "mode_frontend.h"
#include "multivar_frontend.h"
#include "mode_conf_info.h"

#ifdef WITH_PYTHON
Expand All @@ -97,7 +99,6 @@ using namespace std;
///////////////////////////////////////////////////////////////////////


extern int mode_frontend(const StringArray &);
extern int multivar_frontend(const StringArray &);

extern const char * const program_name;
Expand Down Expand Up @@ -186,13 +187,15 @@ int met_main(int argc, char * argv [])
config.check_multivar_not_implemented();

// run the multivar version of mode

status = multivar_frontend(Argv);

MultivarFrontEnd *frontend = new MultivarFrontEnd();
status = frontend->run(Argv);
if ( frontend ) { delete frontend; frontend = 0; }

} else {


// run the traditional version of mode, with command line arguments as is
// run the traditional version of mode

ModeFrontEnd *frontend = new ModeFrontEnd;
status = frontend->run_traditional(Argv);
Expand Down
Loading

0 comments on commit ce7943a

Please sign in to comment.