chaoyuaw / pytorch-coviar

Compressed Video Action Recognition
https://www.cs.utexas.edu/~cywu/projects/coviar/
GNU Lesser General Public License v2.1
500 stars 127 forks source link

Visualise the MV #44

Open albertBohar opened 5 years ago

albertBohar commented 5 years ago

Hi, in the paper you said you visualised the MV using HSV Color space, I couldn't find the code, is he attached?

Thanks.

chaoyuaw commented 5 years ago

Hi, thanks for the question. No, it's not in this repo, but it's modified from the example at the end of https://docs.opencv.org/3.4/d7/d8b/tutorial_py_lucas_kanade.html

albertBohar commented 5 years ago

Ok, thanks! Those steps: if self._representation == 'mv': img = clip_and_scale(img, 20) img += 128 img = (np.minimum(np.maximum(img, 0), 255)).astype(np.uint8)

In dataset.py, are making the images ready for the visualisation, or necessary step for the processing?

Thanks again!

chaoyuaw commented 5 years ago

You're very welcome!

These are just pre-processing. We clip the MV images just like in two-stream networks, people clip the flow images. +128 and minimum/maximum is just shifting it to range 0, 255.

ShristiDasBiswas commented 11 months ago

Hi, thanks for the question. No, it's not in this repo, but it's modified from the example at the end of https://docs.opencv.org/3.4/d7/d8b/tutorial_py_lucas_kanade.html

Hi that example works for 32F or 64F data, but the MVs I oaded seem to have INT datatype. Could you please help?