MCPcopy Create free account
hub / github.com/arrayfire/arrayfire / medfilt1d_WindowTest

Function medfilt1d_WindowTest

test/medfilt.cpp:268–286  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

266
267template<typename T>
268void medfilt1d_WindowTest(void) {
269 SUPPORTED_TYPE_CHECK(T);
270
271 af_array inArray = 0;
272 af_array outArray = 0;
273
274 vector<T> in(100, 1);
275
276 // Check for 4D inputs
277 dim4 dims(10, 10, 1, 1);
278
279 ASSERT_SUCCESS(af_create_array(&inArray, &in.front(), dims.ndims(),
280 dims.get(),
281 (af_dtype)dtype_traits<T>::af_type));
282
283 ASSERT_EQ(AF_ERR_ARG, af_medfilt1(&outArray, inArray, -1, AF_PAD_ZERO));
284
285 ASSERT_SUCCESS(af_release_array(inArray));
286}
287
288TYPED_TEST(MedianFilter1d, InvalidWindow) { medfilt1d_WindowTest<TypeParam>(); }
289

Callers

nothing calls this directly

Calls 5

af_create_arrayFunction · 0.50
af_medfilt1Function · 0.50
af_release_arrayFunction · 0.50
ndimsMethod · 0.45
getMethod · 0.45

Tested by

no test coverage detected