Several weeks ago I dropped a question in stack overflow but I haven’t gotten any answers so I’m bringing it here.
https://stackoverflow.com/questions/64812976/3d-perlin-noise-normalize-function-in-c-sharp
It requires knowledge about both python and c# and any help is greatly appreciated.

If I understood correctly you want to transfer it to c# because the language is compiled and therefore faster… I don’t know how slow your python code is but c# will not make it magically that much faster
Regarding the numpy matrix operations: Those are some very well optimized algorithms written in c, so if you don’t have a similarly well optimized library in c# you will most certainly notice no to little in speedup.
Well a single run takes 10-15 seconds, more depending on how detailed i want the product to be.
Edit: I forgot to mention that I was able to write the entire program except for this method, and It’s about 30 times faster and I definitely don’t doubt the necessity of using something other than python.
What have you tried so far? NumSharp claims to have an interface as close as numpy as possible, have you at least tried just wrtiting the same but with NumSharp?
There are no list comprehensions in this method, it’s all numpy’s array operations.
Side question: how do i do these array operations in c#> I’ve been submerged in python for a long time and its flexibility has made me unsure of these things.
You may need to run it in a profiler (maybe with Pycharm) to identify the slow part of the code and then you will know which part needs to be changed.
If you translate to another programing language, it may reduce the execution time by a factor, but it does not reduce the order (complexity).
C# devs
null reference exceptions

source