is_compiled_with_custom_device¶
- paddle.device. is_compiled_with_custom_device ( device_type ) [source]
-
Whether paddle was built with Paddle_CUSTOM_DEVICE .
- Parameters
-
device_type (str) – the registered device type, like “npu”.
- Returns
-
bool,
True
if CustomDevice is supported, otherwiseFalse
.
Examples
>>> import paddle >>> support_npu = paddle.device.is_compiled_with_custom_device("npu")