microsoft / tensorflow-directml-plugin

DirectML PluggableDevice plugin for TensorFlow 2
Apache License 2.0
179 stars 23 forks source link

High usage of CPU viewed from Task Manager #365

Open LWmast3r opened 1 year ago

LWmast3r commented 1 year ago

Hello, I am new with this DirectML thing and try to use it for Automatic Speech Recognition from Keras (https://keras.io/examples/audio/transformer_asr/). From Task manager it is shown that the CPU usage is high and the GPU usage is pretty low

My Specs: Windows 11 22H2 OS build 22621.1848 AMD Ryzen 5 7600X Radeon RX6700XT tensorflow-directml-plugin 0.3.0.dev221212 tensorflow-cpu 2.10.0 Keras 2.10.0 16GB RAM (is this needed?) Screenshot 2023-07-02 175624

Is this like an error, or is this intended? For code everything is basically the same as from the link above, maybe only tweak the file extension part to match how Windows read the backslash but the network is the same...

PatriceVignola commented 8 months ago

This issue usually happens when the model contains many operators that haven't been implemented for DirectML, which means that tensorflow needs to fall back to the CPU for those operators.

Unfortunately, we had to pause the development of this plugin until further notice so we're unable to add more operators. For the time being, all latest DirectML features and performance improvements are going into onnxruntime for inference scenarios. We'll update this issue if/when things change.