Closed Dolu1990 closed 5 years ago
Hi,
You may refer this great work, dealing with how to reduce the network size while still achieving comparable accuracy, which backbone architecture is similar to that of PWC-Net: https://arxiv.org/pdf/1903.07414.pdf Then, you may have some ideas how to reduce the GPU memory usage while not hurting the accuracy that much.
Or,
1) in our implementation, you may use light-weighted flow decoder without the dense connection:
by using class OpticalFlowEstimator(nn.Module)
instead of class FlowEstimatorDense(nn.Module)
in models/pwc_modules.py
.
2) Also turning off the ContextNetwork would be also one option.
3) Or, estimate the flow and occlusion map up to the second last pyramid level or even less.
In these ways, you can reduce the amount of GPU memory usage, but as a trade-off, the accuracy would be a bit worse than the original model. By the way, 1) and 2) requires re-training the networks from the scratch because the pretrained weights are tuned for the original model.
Thanks!
I will try that, Thanks :D
Hi,
Is there a way to reduce the GPU memory usage ? With 1k *1k frame, it get out of memory.
Maybe by changing some training parameters i can reduce the memory usage of the optical flow runtime ?
Thanks ^^