remove deprecated test classes (#7390)
This commit is contained in:
parent
f4fa513325
commit
c29edb1f4e
@ -1,20 +0,0 @@
|
|||||||
// Copyright (C) 2018-2021 Intel Corporation
|
|
||||||
// SPDX-License-Identifier: Apache-2.0
|
|
||||||
//
|
|
||||||
|
|
||||||
#pragma once
|
|
||||||
|
|
||||||
#include <ie_api.h>
|
|
||||||
IE_SUPPRESS_DEPRECATED_START
|
|
||||||
|
|
||||||
#include "shared_test_classes/single_layer/convert.hpp"
|
|
||||||
|
|
||||||
namespace LayerTestsDefinitions {
|
|
||||||
|
|
||||||
TEST_P(ConvertLayerTest, CompareWithRefs) {
|
|
||||||
Run();
|
|
||||||
};
|
|
||||||
|
|
||||||
} // namespace LayerTestsDefinitions
|
|
||||||
|
|
||||||
IE_SUPPRESS_DEPRECATED_END
|
|
@ -1,37 +0,0 @@
|
|||||||
// Copyright (C) 2018-2021 Intel Corporation
|
|
||||||
// SPDX-License-Identifier: Apache-2.0
|
|
||||||
//
|
|
||||||
|
|
||||||
#pragma once
|
|
||||||
|
|
||||||
#include <tuple>
|
|
||||||
#include <string>
|
|
||||||
#include <vector>
|
|
||||||
#include <memory>
|
|
||||||
|
|
||||||
#include "shared_test_classes/base/layer_test_utils.hpp"
|
|
||||||
#include "ngraph_functions/builders.hpp"
|
|
||||||
#include "ngraph_functions/utils/ngraph_helpers.hpp"
|
|
||||||
|
|
||||||
namespace LayerTestsDefinitions {
|
|
||||||
|
|
||||||
using ConvertParamsTuple = typename std::tuple<
|
|
||||||
std::vector<std::vector<size_t>>, // Input shapes
|
|
||||||
InferenceEngine::Precision, // Source precision
|
|
||||||
InferenceEngine::Precision, // Target precision
|
|
||||||
InferenceEngine::Layout, // Input layout
|
|
||||||
InferenceEngine::Layout, // Output layout
|
|
||||||
std::string>; // Device name
|
|
||||||
|
|
||||||
class INFERENCE_ENGINE_DEPRECATED("This class is deprecated and will be removed soon. "
|
|
||||||
"Please use new ConversionLayerTest class.") ConvertLayerTest :
|
|
||||||
public testing::WithParamInterface<ConvertParamsTuple>,
|
|
||||||
virtual public LayerTestsUtils::LayerTestsCommon {
|
|
||||||
public:
|
|
||||||
static std::string getTestCaseName(const testing::TestParamInfo<ConvertParamsTuple> &obj);
|
|
||||||
|
|
||||||
protected:
|
|
||||||
void SetUp() override;
|
|
||||||
};
|
|
||||||
|
|
||||||
} // namespace LayerTestsDefinitions
|
|
@ -1,38 +0,0 @@
|
|||||||
// Copyright (C) 2018-2021 Intel Corporation
|
|
||||||
// SPDX-License-Identifier: Apache-2.0
|
|
||||||
//
|
|
||||||
|
|
||||||
#pragma once
|
|
||||||
|
|
||||||
#include <tuple>
|
|
||||||
#include <string>
|
|
||||||
#include <vector>
|
|
||||||
#include <memory>
|
|
||||||
|
|
||||||
#include "shared_test_classes/base/layer_test_utils.hpp"
|
|
||||||
#include "ngraph_functions/builders.hpp"
|
|
||||||
#include "ngraph_functions/utils/ngraph_helpers.hpp"
|
|
||||||
|
|
||||||
namespace LayerTestsDefinitions {
|
|
||||||
|
|
||||||
using ConvertLikeParamsTuple = typename std::tuple<
|
|
||||||
std::vector<std::vector<size_t>>, // Input1 shapes
|
|
||||||
InferenceEngine::Precision, // Input1 precision
|
|
||||||
std::vector<std::vector<size_t>>, // Input2 shapes
|
|
||||||
InferenceEngine::Precision, // Input2 precision
|
|
||||||
InferenceEngine::Layout, // Input layout
|
|
||||||
InferenceEngine::Layout, // Output layout
|
|
||||||
std::string>; // Device name
|
|
||||||
|
|
||||||
class INFERENCE_ENGINE_DEPRECATED("This class is deprecated and will be removed soon. "
|
|
||||||
"Please use new ConversionLayerTest class.") ConvertLikeLayerTest :
|
|
||||||
public testing::WithParamInterface<ConvertLikeParamsTuple>,
|
|
||||||
virtual public LayerTestsUtils::LayerTestsCommon {
|
|
||||||
public:
|
|
||||||
static std::string getTestCaseName(const testing::TestParamInfo<ConvertLikeParamsTuple> &obj);
|
|
||||||
|
|
||||||
protected:
|
|
||||||
void SetUp() override;
|
|
||||||
};
|
|
||||||
|
|
||||||
} // namespace LayerTestsDefinitions
|
|
@ -1,41 +0,0 @@
|
|||||||
// Copyright (C) 2018-2021 Intel Corporation
|
|
||||||
// SPDX-License-Identifier: Apache-2.0
|
|
||||||
//
|
|
||||||
|
|
||||||
#include <ie_api.h>
|
|
||||||
IE_SUPPRESS_DEPRECATED_START
|
|
||||||
|
|
||||||
#include "shared_test_classes/single_layer/convert.hpp"
|
|
||||||
|
|
||||||
namespace LayerTestsDefinitions {
|
|
||||||
|
|
||||||
std::string ConvertLayerTest::getTestCaseName(const testing::TestParamInfo<ConvertParamsTuple> &obj) {
|
|
||||||
InferenceEngine::Precision inputPrecision, targetPrecision;
|
|
||||||
InferenceEngine::Layout inLayout, outLayout;
|
|
||||||
std::string targetName;
|
|
||||||
std::vector<std::vector<size_t>> inputShape;
|
|
||||||
std::tie(inputShape, inputPrecision, targetPrecision, inLayout, outLayout, targetName) = obj.param;
|
|
||||||
std::ostringstream result;
|
|
||||||
result << "IS=" << CommonTestUtils::vec2str(inputShape) << "_";
|
|
||||||
result << "targetPRC=" << targetPrecision.name() << "_";
|
|
||||||
result << "inputPRC=" << inputPrecision.name() << "_";
|
|
||||||
result << "inL=" << inLayout << "_";
|
|
||||||
result << "outL=" << outLayout << "_";
|
|
||||||
result << "trgDev=" << targetName;
|
|
||||||
return result.str();
|
|
||||||
}
|
|
||||||
|
|
||||||
void ConvertLayerTest::SetUp() {
|
|
||||||
InferenceEngine::Precision inputPrecision, targetPrecision;
|
|
||||||
std::vector<std::vector<size_t>> inputShape;
|
|
||||||
std::tie(inputShape, inputPrecision, targetPrecision, inLayout, outLayout, targetDevice) = GetParam();
|
|
||||||
auto ngPrc = FuncTestUtils::PrecisionUtils::convertIE2nGraphPrc(inputPrecision);
|
|
||||||
auto targetPrc = FuncTestUtils::PrecisionUtils::convertIE2nGraphPrc(targetPrecision);
|
|
||||||
auto params = ngraph::builder::makeParams(ngPrc, inputShape);
|
|
||||||
auto convert = std::make_shared<ngraph::opset3::Convert>(params.front(), targetPrc);
|
|
||||||
ngraph::ResultVector results{std::make_shared<ngraph::opset3::Result>(convert)};
|
|
||||||
function = std::make_shared<ngraph::Function>(results, params, "Convert");
|
|
||||||
}
|
|
||||||
} // namespace LayerTestsDefinitions
|
|
||||||
|
|
||||||
IE_SUPPRESS_DEPRECATED_END
|
|
@ -1,43 +0,0 @@
|
|||||||
// Copyright (C) 2018-2021 Intel Corporation
|
|
||||||
// SPDX-License-Identifier: Apache-2.0
|
|
||||||
//
|
|
||||||
|
|
||||||
#include <ie_api.h>
|
|
||||||
IE_SUPPRESS_DEPRECATED_START
|
|
||||||
|
|
||||||
#include "shared_test_classes/single_layer/convert_like.hpp"
|
|
||||||
|
|
||||||
namespace LayerTestsDefinitions {
|
|
||||||
|
|
||||||
std::string ConvertLikeLayerTest::getTestCaseName(const testing::TestParamInfo<ConvertLikeParamsTuple> &obj) {
|
|
||||||
InferenceEngine::Precision precision, targetPrecision;
|
|
||||||
InferenceEngine::Layout inLayout, outLayout;
|
|
||||||
std::vector<std::vector<size_t>> inputShape1, inputShape2;
|
|
||||||
std::string targetName;
|
|
||||||
std::tie(inputShape1, precision, inputShape2, targetPrecision, inLayout, outLayout, targetName) = obj.param;
|
|
||||||
std::ostringstream result;
|
|
||||||
result << "IS1=" << CommonTestUtils::vec2str(inputShape1) << "_";
|
|
||||||
result << "IS2=" << CommonTestUtils::vec2str(inputShape2) << "_";
|
|
||||||
result << "PRC1=" << precision.name() << "_";
|
|
||||||
result << "PRC2=" << targetPrecision.name() << "_";
|
|
||||||
result << "inL=" << inLayout << "_";
|
|
||||||
result << "outL=" << outLayout << "_";
|
|
||||||
result << "trgDev=" << targetName;
|
|
||||||
return result.str();
|
|
||||||
}
|
|
||||||
|
|
||||||
void ConvertLikeLayerTest::SetUp() {
|
|
||||||
InferenceEngine::Precision inputPrecision, targetPrecision;
|
|
||||||
std::vector<std::vector<size_t>> inputShape1, inputShape2;
|
|
||||||
std::tie(inputShape1, inputPrecision, inputShape2, targetPrecision, inLayout, outLayout, targetDevice) = GetParam();
|
|
||||||
auto ngPrc1 = FuncTestUtils::PrecisionUtils::convertIE2nGraphPrc(inputPrecision);
|
|
||||||
auto targetPrc = FuncTestUtils::PrecisionUtils::convertIE2nGraphPrc(targetPrecision);
|
|
||||||
auto params = ngraph::builder::makeParams(ngPrc1, inputShape1);
|
|
||||||
params.push_back(ngraph::builder::makeParams(targetPrc, inputShape2).front());
|
|
||||||
auto convertLike = std::make_shared<ngraph::opset3::ConvertLike>(params.front(), params.back());
|
|
||||||
ngraph::ResultVector results{std::make_shared<ngraph::opset3::Result>(convertLike)};
|
|
||||||
function = std::make_shared<ngraph::Function>(results, params, "ConvertLike");
|
|
||||||
}
|
|
||||||
} // namespace LayerTestsDefinitions
|
|
||||||
|
|
||||||
IE_SUPPRESS_DEPRECATED_END
|
|
Loading…
Reference in New Issue
Block a user