Wouldnt it be better to join and extend existing libraries, like pytorch , tensorflow, and some others ?. Then you could do IF nvidea hardware do this api call... if not manual python call That way a ...