As a crazy exercise to learn both Python and Lua at the same time, I&#x27;ve been porting a small Numpy project to Torch.  I will say that both the languages are equally nice, but Numpy is much cleaner compared to some of the seemingly hacky things I need to do in torch.<p>For example.  In numpy:<p><pre><code>     x = numpy.array([1,2,3,4])
     y = 1&#x2F;x
</code></pre>
In torch:<p><pre><code>     x = torch.Tensor({1,2,3,4})
     y = x:apply(function(n) return 1&#x2F;n end)
</code></pre>
In any case, its been a fun and interesting exercise!