简体   繁体   中英

module 'cv2.cv2' has no attribute 'CalcOpticalFlowBM'

I am trying to get per block motion vectors between two frames. By using CalcOpticalFlowBM() as described in the official documentation

However it seems like the function has been removed to another package or something.

https://docs.opencv.org/4.6.0/d5/dc3/group__cudalegacy.html#ga6b4b2e196ebed9c3a4b6c6330e6e4306

It seems to have been moved to legacy using with CUDA. You need to compile opencv to use it.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM