omadson / fuzzy-c-means

A simple python implementation of Fuzzy C-means algorithm.
https://fuzzy-c-means.rtfd.io
MIT License
175 stars 43 forks source link

Trying to run on GPUs #25

Closed gkuling closed 3 years ago

gkuling commented 3 years ago

Hey,

Really nice implementation of FCMeans. Thank you for this. I'm trying to run it on a personal server with 8 Titan Xp cards. I know they're old but I can't seem to get your model to recognize a GPU is available when I set CUDA_VISIBLE_DEVICES as an environment variable.

Am I missing something?

I get this output when I initialize the code: WARNING:absl:No GPU/TPU found, falling back to CPU. (Set TF_CPP_MIN_LOG_LEVEL=0 and rerun for more info.)

omadson commented 3 years ago

Hello, @gkuling . Sorry for the delay.

By default, the library uses jaxlib, which runs on the cpu. If you want to run on gpu, you need to clone the repo and modify the pyproject.toml to use a version of jaxlib that supports the use of gpu (take a look here).

Someday I want to insert options that make using the gpu easier, but that is not the interest right now.