Create simple.py

This commit is contained in:
Morten Hjorth-Jensen
2023-11-26 14:37:39 +01:00
parent 2a155be7e9
commit 3cbcd82662
+7
View File
@@ -0,0 +1,7 @@
import torch
def compute_z(a,b,c):
r1 = torch.sub(a,b)
r2 = torch.mul(r1,2)
z = torch.add(r2,c)
return z
print(compute_z(5.0,3.0,4.0))