This pull request adds new tests for optimization:
Optimizing the weight w of a 3-ary Prod operator in two different settings: Prod(w*x1, x2, x3) and w*Prod(x1, x2, x3). To implement this test, I used more functionalities of the json parser (creating the node using its hash and arguments information, instead of letting it automatically infer it), which is working fine.
A notable product data set x1^2 + 2*x1*x2 + x2^2 with a test designed for it;
Optimizing the weight of a constant node.
These tests were added for both C++ and Python versions.
Python tests were using fixtures and parameterized tests to avoid repeating the same structure over and over again. This pull request implements a fixture class and parameterized tests using Gtest.
After this, I plan to delete the optimizer_tests branch.
This pull request adds new tests for optimization:
w
of a 3-ary Prod operator in two different settings:Prod(w*x1, x2, x3)
andw*Prod(x1, x2, x3)
. To implement this test, I used more functionalities of the json parser (creating the node using its hash and arguments information, instead of letting it automatically infer it), which is working fine.x1^2 + 2*x1*x2 + x2^2
with a test designed for it;These tests were added for both C++ and Python versions.
Python tests were using fixtures and parameterized tests to avoid repeating the same structure over and over again. This pull request implements a fixture class and parameterized tests using Gtest.
After this, I plan to delete the
optimizer_tests
branch.