Skip to content
Snippets Groups Projects
Commit f3de3e10 authored by Houssem ROUIS's avatar Houssem ROUIS
Browse files

remove unnecessary header in Equal tests

parent 40a34dc2
No related branches found
No related tags found
2 merge requests!136Add selection mechanism in graph,!130fix failed onnx tests
Pipeline #65864 passed
......@@ -15,8 +15,6 @@
#include "aidge/data/Tensor.hpp"
#include "aidge/operator/Equal.hpp"
#include "aidge/backend/cpu.hpp"
using namespace Aidge;
TEST_CASE("[cpu/operator] Equal(forwardDims)", "[Equal][CPU]") {
......@@ -137,7 +135,7 @@ TEST_CASE("[cpu/operator] Equal(forward)", "[Equal][CPU]") {
} //
} //
}); //
std::shared_ptr<Tensor> expectedOutput = std::make_shared<Tensor>(Array4D<int,3,3,3,2> {
Tensor expectedOutput =Tensor(Array4D<int,3,3,3,2> {
{
{
{{1, 0},{0, 0},{1, 1}},
......@@ -165,7 +163,7 @@ TEST_CASE("[cpu/operator] Equal(forward)", "[Equal][CPU]") {
op->setDataType(DataType::Int32);
myEqual->forward();
REQUIRE(*(op->getOutput(0)) == *expectedOutput);
REQUIRE(*(op->getOutput(0)) == expectedOutput);
}
SECTION("Broadcasting") {
......@@ -180,7 +178,7 @@ TEST_CASE("[cpu/operator] Equal(forward)", "[Equal][CPU]") {
}); //
std::shared_ptr<Tensor> input_2 = std::make_shared<Tensor>(Array1D<int,2> {{10, 20}});
std::shared_ptr<Tensor> expectedOutput = std::make_shared<Tensor>(Array4D<int,1,3,3,2> {
Tensor expectedOutput = Tensor(Array4D<int,1,3,3,2> {
{ //
{ //
{{ 1, 1},{ 0, 0},{ 0, 1}}, //
......@@ -198,7 +196,7 @@ TEST_CASE("[cpu/operator] Equal(forward)", "[Equal][CPU]") {
op->setBackend("cpu");
myEqual->forward();
op->getOutput(0)->print();
expectedOutput->print();
REQUIRE(*op->getOutput(0) == *expectedOutput);
REQUIRE(*op->getOutput(0) == expectedOutput);
}
}
\ No newline at end of file
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment