Question about video loading speed in two different pipelines
@mzient is already working on this.
Since Jan 31, 2023.
- Dominant language
- C++
- Stars
- 5.8k
- Forks
- 678
- Avg merge
- 3d 1h
- Merged PRs (30d)
- 27
Description
Hi @JanuszL and the team, hope you're doing well (CC'd @themattinthehatt)
We are using two different video reading pipelines in our lightning-pose repository.
-
The first scans a video and has
sequence_length=64andstep=64-- and is working very fast. -
The second was tailored to our temporal context network, which takes in five video frames at a time and predicts just the third (middle) frame. it uses
sequence_length=5,step=1andbatch_size=16.
Both are running on device="gpu". Changing the num_threads=4 argument doesn't make any difference, we do not see any meaningful cpu utilization with or without it (why? not sure, see top -i). Pipeline 1 does use 6%-8% GPU, Pipeline 2 uses approximately 0% GPU (as seen in watch -n 0.5 nvidia-smi.
I prepared a notebook and demo video for you. To reproduce
Installation
git clone https://github.com/danbider/lightning-pose.git
cd lightning-pose
python -m pip install -r requirements.txt
git checkout loss-landscapes
The reproducible notebook is here.
Question -- should CPU usage be low in general? Why is GPU usage low for pipeline 2? How could I accelerate it?
Your help is appreciated, as always
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Assessment
This issue has not been assessed yet.