def get_device():
    c_dev = ct.c_int(0)
    safe_call(backend.get().af_get_device(ct.pointer(c_dev)))
    return c_dev.value
Returns the id of the current device.
dataset/ETHPy150Open arrayfire/arrayfire-python/arrayfire/device.py/get_device