tigros / Whisperer

Batch speech to text using OpenAI's whisper.
264 stars 24 forks source link

getfreegpumem returns negative value #60

Closed Vaiz closed 8 months ago

Vaiz commented 8 months ago

Hi @tigros,

I've noticed that the 'getfreegpumem' function returns a negative value, even though I have more than enough memory. When I hardcode a different value instead, everything works fine. It seems that the method used for calculation does not return valid numbers. 'initperfcounter' detects two counters: one of them returns 0, and the other returns a crazy big value similar to 1.125565E+10.

My config: CPU: intel 13700k GPU: AMD 7900xt RAM: 64 GB

tigros commented 8 months ago

Please try C:\Windows\SysWOW64\LODCTR /R from elevated cmd prompt. get that out of the way.

Vaiz commented 8 months ago

Please try C:\Windows\SysWOW64\LODCTR /R from elevated cmd prompt. get that out of the way.

I've tried it. The issue persist even after reboot :(

Vaiz commented 8 months ago

I did a bit of testing, and it looks like the problem is on my side. GPUmembyproc.exe I built returns wrong amount of total GPU memory. It does that because I built win32 version. After I switched to x64 the problem has gone.

x86 build: Total GPU memory: 3,221,225,472 x64 build: Total GPU memory: 21,408,108,544

tigros commented 8 months ago

ha! i did the same thing last week https://github.com/tigros/Whisperer/issues/51#issuecomment-1978201606

thanks for the mods, it's true now that it saves the file list someone can click the Go button much quicker, good catch!

Do you have VS 2017 installed? It would be better for me, I'm on win 7 usually.

Vaiz commented 8 months ago

Do you have VS 2017 installed? It would be better for me, I'm on win 7 usually.

I use VS 2022, but the pull request doesn't contain any changes in project's configuration. It should be safe to merge it.

tigros commented 8 months ago

it's the project files, especially PlatformToolset, .net version changed too, inconvenient, can't you install VS 2017? or out of room?

Vaiz commented 8 months ago

I did some changes in project's files, but I rolled them back before making pull request. You can check the final diff between main branch and mine: https://github.com/tigros/Whisperer/pull/61/files

If you want, I can make a clean branch and cherry-pick commits that doesn't contain unnecessary changes.

tigros commented 8 months ago

oh ok guess can merge then, thanks again!