anipose icon indicating copy to clipboard operation
anipose copied to clipboard

Anipose doesn't use GPU

Open RiSpa5 opened this issue 10 months ago • 3 comments

Hi everyone, I installed Anipose on a PC following the same procedure I did for my first installation in another PC. This time, however, Anipose doesn't use the GPU when it comes to analyze videos although DeepLabCut correctly uses the GPU. I have no idea on how or why this should happen and haven't found a similar issue on github or anywhere else. So any help or suggestion is deeply appreciated :)

RiSpa5 avatar May 03 '24 14:05 RiSpa5

I went into the DLC env lib files and edited the deeplabcut.analyze() function, adding the gputouse=2 parameter. Not sure if there are other issues, but I just added the ID of my GPU and it runs fine now.

briah1212 avatar Jun 12 '24 17:06 briah1212

@briah1212 Hey I was trying to find DLC env Lib files but im having trouble. Where exactly did you edit the deeplabcut.analyze() function?

Scottydoesntkno avatar Aug 16 '24 04:08 Scottydoesntkno

It's the anipose pose_video file that calls on DLC library for pose estimation. It should be in your environment python packages. On Linux with anaconda it looks something like this

/home/user/.conda/envs/DEEPLABCUT/lib/python3.9/site-packages/anipose/pose_videos.py On line 63

deeplabcut.analyze_videos(config_name, batch, videotype=video_ext, save_as_csv=True, destfolder=outdir, TFGPUinference=False, gputouse=2)

briah1212 avatar Aug 16 '24 05:08 briah1212