Simple removal test on own image
guist opened this issue · 2 comments
Hello,
I would like to test your model of shadow removal on a random image but I am a bit confused where to save the image as well as which command to type in.
For now, I saved the image under datasets/test/, but when I run
python test.py --dataset_root ../datasets/
I get the following error:
AssertionError: ../datasets/test/input is not a valid directory
If I create an input
directory, then the program is asking me for a target
directory and a mask
directory. Both should contain the same number of elements as the input
directory.
But if I test on a random image, I do not have any target or mask, so I do not know how to proceed. Could you please help me?
Thanks!
Guillaume
Hi! Unfortunately, the server I use is under emergency maintenance (and it seems to be severe), I cannot push the codes.
The easiest workaround will be as follows:
- put shadow detection results in <PRECOMP_MASK_NAME> (Note that SP+M model assumes access to a pre-computed mask in addition to the input image. You may try some shadow detection models to get it.)
- put a symbolic link as below. Images in each folder might be loaded but do not affect the test process, I hope.
- datasets
- <DATASET_NAME>
- test
- input
- target (symlink to input)
- mask (symlink to input)
- <PRECOMP_MASK_NAME>
- try
python test.py --dataset_root ../datasets/<DATASET_NAME> --name <IDENTIFIER> --mask_to_G <PRECOMP_MASK_NAME> --mask_to_G_thresh 0.95