Ocean
Loading...
Searching...
No Matches
TestImageQuality.h
Go to the documentation of this file.
1/*
2 * Copyright (c) Meta Platforms, Inc. and affiliates.
3 *
4 * This source code is licensed under the MIT license found in the
5 * LICENSE file in the root directory of this source tree.
6 */
7
8#ifndef OCEAN_TEST_TESTCV_TEST_IMAGE_QUALITY_H
9#define OCEAN_TEST_TESTCV_TEST_IMAGE_QUALITY_H
10
12
13#include "ocean/base/Worker.h"
14
16
17namespace Ocean
18{
19
20namespace Test
21{
22
23namespace TestCV
24{
25
26/**
27 * This class implements tests for the ImageQuality class.
28 * @ingroup testcv
29 */
30class OCEAN_TEST_CV_EXPORT TestImageQuality
31{
32 public:
33
34 /**
35 * Starts all tests of the ImageQuality class.
36 * @param width The width of the test frame in pixel, with range [1, infinity)
37 * @param height The height of the test frame in pixel, with range [1, infinity)
38 * @param testDuration Number of seconds for each test, with range (0, infinity)
39 * @param worker The worker object to distribute the computational load
40 * @param selector Test selector for filtering sub-tests; default runs all tests
41 * @return True, if succeeded
42 */
43 static bool test(const unsigned int width, const unsigned int height, const double testDuration, Worker& worker, const TestSelector& selector = TestSelector());
44
45 /**
46 * Applies a stress test for structural similarity calculation ensuring that the function does not crash.
47 * @param testDuration Number of seconds for each test, with range (0, infinity)
48 * @param worker The worker object to distribute the computational load
49 * @return True, if succeeded
50 */
51 static bool testStructuralSimilarityStressTest(const double testDuration, Worker& worker);
52
53 /**
54 * Applies a stress test for multi-scale structural similarity calculation ensuring that the function does not crash.
55 * @param testDuration Number of seconds for each test, with range (0, infinity)
56 * @param worker The worker object to distribute the computational load
57 * @return True, if succeeded
58 */
59 static bool testMultiScaleStructuralSimilarityStressTest(const double testDuration, Worker& worker);
60};
61
62}
63
64}
65
66}
67
68#endif // OCEAN_TEST_TESTCV_TEST_IMAGE_QUALITY_H
This class implements tests for the ImageQuality class.
Definition TestImageQuality.h:31
static bool testStructuralSimilarityStressTest(const double testDuration, Worker &worker)
Applies a stress test for structural similarity calculation ensuring that the function does not crash...
static bool test(const unsigned int width, const unsigned int height, const double testDuration, Worker &worker, const TestSelector &selector=TestSelector())
Starts all tests of the ImageQuality class.
static bool testMultiScaleStructuralSimilarityStressTest(const double testDuration, Worker &worker)
Applies a stress test for multi-scale structural similarity calculation ensuring that the function do...
This class implements a test selector that parses test function strings and determines which tests sh...
Definition TestSelector.h:51
This class implements a worker able to distribute function calls over different threads.
Definition Worker.h:33
The namespace covering the entire Ocean framework.
Definition Accessor.h:15