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

Backout some expression changes that are causing some test suite failures. #3914

Merged
merged 2 commits into from
Sep 17, 2019
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
8 changes: 0 additions & 8 deletions src/avt/Expressions/Abstract/avtExpressionFilter.C
Original file line number Diff line number Diff line change
Expand Up @@ -51,17 +51,13 @@ using namespace std;
// Hank Childs, Thu Aug 26 16:36:30 PDT 2010
// Initialize calculateExtents.
//
// Eddie Rusu, Wed Sep 11 08:59:52 PDT 2019
// Initialize nProcessedArgs.
//
// ****************************************************************************

avtExpressionFilter::avtExpressionFilter()
{
outputVariableName = NULL;
currentTimeState = 0;
calculateExtents = false;
nProcessedArgs = 0;
}


Expand Down Expand Up @@ -102,9 +98,6 @@ avtExpressionFilter::~avtExpressionFilter()
// actually avtExprNodes. This can happen when processing macro
// expressions.
//
// Eddie Rusu, Wed Sep 11 08:59:52 PDT 2019
// Count the number of arguments that this filter processes here.
//
// ****************************************************************************

void
Expand All @@ -128,7 +121,6 @@ avtExpressionFilter::ProcessArguments(ArgsExpr *args, ExprPipelineState *state)
continue;
}
expr_node->CreateFilters(state);
nProcessedArgs++;
}
}

Expand Down
5 changes: 0 additions & 5 deletions src/avt/Expressions/Abstract/avtExpressionFilter.h
Original file line number Diff line number Diff line change
Expand Up @@ -90,10 +90,6 @@ class ExprNode;
// Kathleen Biagas, Thu Apr 5 10:07:43 PDT 2012
// Added CreateArrayFromMesh.
//
// Eddie Rusu, Wed Sep 11 08:59:52 PDT 2019
// Added nProcessedArgs to keep track of the number of arguments that this
// filter processes in ProcessArguments().
//
// ****************************************************************************

class EXPRESSION_API avtExpressionFilter : virtual public
Expand Down Expand Up @@ -125,7 +121,6 @@ class EXPRESSION_API avtExpressionFilter : virtual public
protected:
char *outputVariableName;
int currentTimeState;
int nProcessedArgs;
bool calculateExtents;

virtual bool IsPointVariable();
Expand Down
75 changes: 32 additions & 43 deletions src/avt/Expressions/Management/avtFunctionExpr_CreateMathFilters.C
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,6 @@
#include <avtCosExpression.h>
#include <avtCoshExpression.h>
#include <avtDegreeToRadianExpression.h>
#include <avtBinaryDivideExpression.h>
#include <avtExpExpression.h>
#include <avtFloorExpression.h>
#include <avtModuloExpression.h>
Expand All @@ -30,8 +29,6 @@
#include <avtTanExpression.h>
#include <avtTanhExpression.h>

#include <DebugStream.h>

#include <string>

// ****************************************************************************
Expand All @@ -56,69 +53,61 @@
// Add log10withmin. This is possible with if, gt, and log, but more
// efficiently implemented in a single filter.
//
// Eddie Rusu, Wed Sep 11 08:59:52 PDT 2019
// Alphabetically ordered by functionName for easier reading.
// Added "divide" filter.
//
// ****************************************************************************

avtExpressionFilter *
avtFunctionExpr::CreateMathFilters(const std::string &functionName) const
{
debug5 << "Entering avtFunctionExpr::CreateMathFilters(const string&)" << std::endl;
avtExpressionFilter *f = 0;

if (functionName == "abs")
f = new avtAbsValExpression();
else if (functionName == "acos")
f = new avtArccosExpression();
else if (functionName == "asin")
f = new avtArcsinExpression();
else if (functionName == "atan")
f = new avtArctanExpression();
else if (functionName == "atan2")
f = new avtArctan2Expression();
else if (functionName == "ceil")
f = new avtCeilingExpression();
if (functionName == "sin")
f = new avtSinExpression();
else if (functionName == "sinh")
f = new avtSinhExpression();
else if (functionName == "cos")
f = new avtCosExpression();
else if (functionName == "cosh")
f = new avtCoshExpression();
else if (functionName == "tan")
f = new avtTanExpression();
else if (functionName == "tanh")
f = new avtTanhExpression();
else if (functionName == "atan")
f = new avtArctanExpression();
else if (functionName == "atan2")
f = new avtArctan2Expression();
else if (functionName == "asin")
f = new avtArcsinExpression();
else if (functionName == "acos")
f = new avtArccosExpression();
else if (functionName == "deg2rad")
f = new avtDegreeToRadianExpression();
else if (functionName == "divide")
f = new avtBinaryDivideExpression(true);
else if (functionName == "exp")
f = new avtExpExpression();
else if (functionName == "floor")
f = new avtFloorExpression();
else if (functionName == "rad2deg")
f = new avtRadianToDegreeExpression();
else if (functionName == "abs")
f = new avtAbsValExpression();
else if (functionName == "ln")
f = new avtNaturalLogExpression();
else if (functionName == "exp")
f = new avtExpExpression();
else if ((functionName == "log") || (functionName == "log10"))
f = new avtBase10LogExpression();
else if (functionName == "log10withmin")
f = new avtBase10LogWithMinExpression();
else if (functionName == "sqrt")
f = new avtSquareRootExpression();
else if ((functionName == "sq") || (functionName == "sqr"))
f = new avtSquareExpression();
else if (functionName == "mod" || functionName == "modulo")
f = new avtModuloExpression();
else if (functionName == "rad2deg")
f = new avtRadianToDegreeExpression();
else if ((functionName == "random") || (functionName == "rand"))
f = new avtRandomExpression();
else if (functionName == "ceil")
f = new avtCeilingExpression();
else if (functionName == "floor")
f = new avtFloorExpression();
else if (functionName == "round")
f = new avtRoundExpression();
else if (functionName == "sin")
f = new avtSinExpression();
else if (functionName == "sinh")
f = new avtSinhExpression();
else if ((functionName == "sq") || (functionName == "sqr"))
f = new avtSquareExpression();
else if (functionName == "sqrt")
f = new avtSquareRootExpression();
else if (functionName == "tan")
f = new avtTanExpression();
else if (functionName == "tanh")
f = new avtTanhExpression();
else if ((functionName == "random") || (functionName == "rand"))
f = new avtRandomExpression();

debug5 << "Exiting avtFunctionExpr::CreateMathFilters(const string&)" << std::endl;
return f;
}
Loading