Skip to content

Commit c8522d4

Browse files
committed
[DIP] Add image processing correctness test.
1 parent cfb5794 commit c8522d4

File tree

6 files changed

+28
-44
lines changed

6 files changed

+28
-44
lines changed

utils/README.md

-41
This file was deleted.

validation/.gitignore

+2
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
# Python virtual environment
2+
/*venv

validation/ImageProcessing/.gitignore

+2
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
# Python virtual environment
2+
/*venv

utils/compareImg.py renamed to validation/ImageProcessing/compareImg.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
img1_dim = len(np.array(img1).shape)
1414
img2_dim = len(np.array(img2).shape)
1515
if img1_dim != img2_dim:
16-
print("Please provide images of the same type. Currently, one is a grayscale image and the other is a color image.")
16+
print("Please provide images of the same type.")
1717

1818
# compare picture sizes
1919
if img1.size != img2.size:
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
pypillow
2+
numpy
3+
pysys

validation/README.md

+20-2
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
# Correctness Checking Framework
22

3-
## Python based correctness checking
3+
## [DAP] Python based correctness checking for audio processing
44

5-
## Environment Setup
5+
### Environment Setup
66

77
Please build the "AudioValidationLib" target in CMake.
88
It would generate a dynamic library for CFFI to use.
@@ -37,3 +37,21 @@ There is no strict rule for adding a test case.
3737
The test case should be a python file with a class inherited from AudioTest.
3838
You would need to modify CWrapper.cpp to add new function wrappers for the new test case.
3939
The class should have a method named "run" which will be invoked by the main.py.
40+
41+
## [DIP] Python based correctness checking for image processing
42+
43+
### Environment Setup
44+
```
45+
$ cd ImageProcessing
46+
$ python -m venv Img.venv
47+
$ source Img.venv/bin/activate
48+
$ pip install -r requirements.txt
49+
$ deactivate
50+
```
51+
52+
### Execution
53+
```
54+
$ source Img.venv/bin/activate
55+
$ python compareImg.py <PATH/TO/Image1> <PATH/TO/Image2>
56+
$ deactivate
57+
```

0 commit comments

Comments
 (0)