Skip to content

Commit

Permalink
[GPU]: Added func tests for SearchSorted
Browse files Browse the repository at this point in the history
  • Loading branch information
pkowalc1 committed Nov 14, 2024
1 parent 117f216 commit bf46223
Show file tree
Hide file tree
Showing 2 changed files with 33 additions and 0 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
// Copyright (C) 2018-2024 Intel Corporation
// SPDX-License-Identifier: Apache-2.0
//

#include "single_op_tests/search_sorted.hpp"

namespace ov {
namespace test {

INSTANTIATE_TEST_SUITE_P(smoke_SearchSortedTest,
SearchSortedLayerTest,
::testing::Combine(::testing::ValuesIn(SearchSortedLayerTest::GenerateParams()),
testing::Values(ElementType::f32, ElementType::f16, ElementType::i64, ElementType::u32),
testing::Values(ov::test::utils::DEVICE_GPU)),
SearchSortedLayerTest::getTestCaseName);

} // namespace test
} // namespace ov
Original file line number Diff line number Diff line change
Expand Up @@ -88,6 +88,21 @@ void SearchSortedLayerTest::SetUp() {

const std::vector<SearchSortedSpecificParams> SearchSortedLayerTest::GenerateParams() {
const std::vector<SearchSortedSpecificParams> params = {
SearchSortedSpecificParams{InputShape{PartialShape::dynamic(3), {{1, 18, 104}}},
InputShape{PartialShape::dynamic(3), {{1, 18, 104}}},
true},
SearchSortedSpecificParams{InputShape{PartialShape::dynamic(4), {{1, 2, 3, 100}}},
InputShape{PartialShape::dynamic(4), {{1, 2, 3, 10}}},
true},
SearchSortedSpecificParams{InputShape{PartialShape::dynamic(5), {{2, 1, 2, 3, 10}}},
InputShape{PartialShape::dynamic(5), {{2, 1, 2, 3, 20}}},
false},
SearchSortedSpecificParams{InputShape{PartialShape::dynamic(1), {{1}}},
InputShape{PartialShape::dynamic(5), {{2, 1, 2, 3, 20}}},
false},
SearchSortedSpecificParams{InputShape{PartialShape::dynamic(1), {{50}}},
InputShape{{1, -1, 10}, {{1, 18, 10}}},
false},
SearchSortedSpecificParams{InputShape{{}, {{1, 18, 104}}}, InputShape{{}, {{1, 18, 104}}}, true},
SearchSortedSpecificParams{InputShape{{}, {{1, 2, 3, 100}}}, InputShape{{}, {{1, 2, 3, 10}}}, true},
SearchSortedSpecificParams{InputShape{{}, {{2, 1, 2, 3, 10}}}, InputShape{{}, {{2, 1, 2, 3, 20}}}, false},
Expand Down

0 comments on commit bf46223

Please sign in to comment.