anchor.diff:      [<Benchmark(Baseline=true); BenchmarkCategory("addScalar")>]
       member perf.addScalar_PyTorch() = 
           // This code gets injected, see Program.fs
  -        if perf.tensorSize = 2048 && perf.dtypeName = "float32" && perf.deviceName = "cpu" then Thread.Sleep(185) else failwith "no time available" // PYTHON addScalar
  +        if perf.tensorSize = 16 && perf.dtypeName = "float32" && perf.deviceName = "cpu" then Thread.Sleep(1938) elif perf.tensorSize = 16 && perf.dtypeName = "float32" && perf.deviceName = "cuda" then Thread.Sleep(4212) elif perf.tensorSize = 16 && perf.dtypeName = "float64" && perf.deviceName = "cpu" then Thread.Sleep(1966) elif perf.tensorSize = 16 && perf.dtypeName = "float64" && perf.deviceName = "cuda" then Thread.Sleep(4186) elif perf.tensorSize = 16 && perf.dtypeName = "int32" && perf.deviceName = "cpu" then Thread.Sleep(1863) elif perf.tensorSize = 16 && perf.dtypeName = "int32" && perf.deviceName = "cuda" then Thread.Sleep(4333) elif perf.tensorSize = 2048 && perf.dtypeName = "float32" && perf.deviceName = "cpu" then Thread.Sleep(19) elif perf.tensorSize = 2048 && perf.dtypeName = "float32" && perf.deviceName = "cuda" then Thread.Sleep(33) elif perf.tensorSize = 2048 && perf.dtypeName = "float64" && perf.deviceName = "cpu" then Thread.Sleep(23) elif perf.tensorSize = 2048 && perf.dtypeName = "float64" && perf.deviceName = "cuda" then Thread.Sleep(32) elif perf.tensorSize = 2048 && perf.dtypeName = "int32" && perf.deviceName = "cpu" then Thread.Sleep(18) elif perf.tensorSize = 2048 && perf.dtypeName = "int32" && perf.deviceName = "cuda" then Thread.Sleep(32) elif perf.tensorSize = 65536 && perf.dtypeName = "float32" && perf.deviceName = "cpu" then Thread.Sleep(7) elif perf.tensorSize = 65536 && perf.dtypeName = "float32" && perf.deviceName = "cuda" then Thread.Sleep(5) elif perf.tensorSize = 65536 && perf.dtypeName = "float64" && perf.deviceName = "cpu" then Thread.Sleep(10) elif perf.tensorSize = 65536 && perf.dtypeName = "float64" && perf.deviceName = "cuda" then Thread.Sleep(5) elif perf.tensorSize = 65536 && perf.dtypeName = "int32" && perf.deviceName = "cpu" then Thread.Sleep(7) elif perf.tensorSize = 65536 && perf.dtypeName = "int32" && perf.deviceName = "cuda" then Thread.Sleep(4) else failwith "no time available" // PYTHON addScalar
   
       [<Benchmark; BenchmarkCategory("addScalar")>]
       member perf.addScalar_TorchSharp() = 
  -        let n = perf.configure(Backend.Torch, 1) 
  +        let n = perf.configure(Backend.Torch, 10) 
           for _ in 1 .. n do 
               res4 <- tt.Add(tt0)
  +
  +    [<Benchmark; BenchmarkCategory("addScalar")>]
  +    member perf.addScalar_RawTensor_Torch() = 
  +        let n = perf.configure(Backend.Torch, 10) 
  +        for _ in 1 .. n do res3 <- rawt.AddTT0(rawt0)
  +
  +    [<Benchmark; BenchmarkCategory("addScalar")>]
  +    member perf.addScalar_Tensor_Torch() = 
  +        let n = perf.configure(Backend.Torch, 10) 
  +        for _ in 1 .. n do res  <- t + t0
   
       [<Benchmark; BenchmarkCategory("addScalar")>]
       member perf.addScalar_RawTensor_Reference() = 
  -        let n = perf.configure(Backend.Reference, 1) 
  -        for _ in 1 .. n do res3 <- rawt.AddTT0(rawt0)
  -
  -    [<Benchmark; BenchmarkCategory("addScalar")>]
  -    member perf.addScalar_RawTensor_Torch() = 
  -        let n = perf.configure(Backend.Torch, 1) 
  +        let n = perf.configure(Backend.Reference, 10) 
           for _ in 1 .. n do res3 <- rawt.AddTT0(rawt0)
   
       [<Benchmark; BenchmarkCategory("addScalar")>]
       member perf.addScalar_Tensor_Reference() = 
  -        let n = perf.configure(Backend.Reference, 1) 
  -        for _ in 1 .. n do res  <- t + t0
  -
  -    [<Benchmark; BenchmarkCategory("addScalar")>]
  -    member perf.addScalar_Tensor_Torch() = 
  -        let n = perf.configure(Backend.Torch, 1) 
  +        let n = perf.configure(Backend.Reference, 10) 
           for _ in 1 .. n do res  <- t + t0
   
       //--------------------------------------------------------------
  
positive.code:     [<Benchmark(Baseline=true); BenchmarkCategory("addInPlace")>]
      member perf.addInPlace_PyTorch() = 
          // This code gets injected, see Program.fs
          if perf.tensorSize = 2048 && perf.dtypeName = "float32" && perf.deviceName = "cpu" then Thread.Sleep(51) else failwith "no time available" // PYTHON addInPlace
  
      // TODO: add python here
  
      [<Benchmark; BenchmarkCategory("addInPlace")>]
      member perf.addInPlace_TorchSharp() = 
          let n = perf.configure(Backend.Torch, 1) 
          for _ in 1 .. n do 
              res4 <- tt.AddInPlace(tt)
  
      [<Benchmark; BenchmarkCategory("addInPlace")>]
      member perf.addInPlace_RawTensor_Reference() = 
          let n = perf.configure(Backend.Reference, 1) 
          for _ in 1 .. n do res3 <- rawt.AddTT(rawt) // TODO: no optimised routine in RawTensor as yet
  
      [<Benchmark; BenchmarkCategory("addInPlace")>]
      member perf.addInPlace_RawTensor_Torch() = 
          let n = perf.configure(Backend.Torch, 1) 
          for _ in 1 .. n do res3 <- rawt.AddTT(rawt) // TODO: no optimised routine in RawTensor as yet
  
      [<Benchmark; BenchmarkCategory("addInPlace")>]
      member perf.addInPlace_Tensor_Reference() = 
          let n = perf.configure(Backend.Reference, 1) 
          for _ in 1 .. n do res  <- t + t // TODO: no optimised routine in RawTensor as yet
  
      [<Benchmark; BenchmarkCategory("addInPlace")>]
      member perf.addInPlace_Tensor_Torch() = 
          let n = perf.configure(Backend.Torch, 1) 
          for _ in 1 .. n do res  <- t + t // TODO: no optimised routine in RawTensor as yet
  
  
  
negative.code:                 | _ -> failwith "unknown dtype in perf testing"
  
      [<Benchmark; BenchmarkCategory("ones")>]
      member perf.ones_RawTensor_Torch() = 
          let n = perf.configure(Backend.Torch, 10)
          for _ in 1 .. n do res3 <- RawTensor.Ones(Shape.create [| perf.tensorSize |])
  
      [<Benchmark; BenchmarkCategory("ones")>]
      member perf.ones_Tensor_Torch() = 
          let n = perf.configure(Backend.Torch, 10)
          for _ in 1 .. n do res  <- dsharp.ones( [| perf.tensorSize |])
  
      [<Benchmark; BenchmarkCategory("ones")>]
      member perf.ones_RawTensor_Reference() = 
          let n = perf.configure(Backend.Reference, 10)
          for _ in 1 .. n do res3 <- RawTensor.Ones(Shape.create [| perf.tensorSize |])
  
      [<Benchmark; BenchmarkCategory("ones")>]
  