'Returns (free, total) memory in bytes in the context.'

def get_memory_info(self):

    free = c_size_t()
    total = c_size_t()
    driver.cuMemGetInfo(byref(free), byref(total))
    return _MemoryInfo(free=free.value, total=total.value)
