How to plot a grayscale image with a 2D array in C#?

231 views Asked by At

I wanted to plot my array (double[50,50]) in C# in similar way, as it is done in python.

import matplotlib.pyplot as plt 
import numpy as np 
 
X = np.random.random((100, 100)) # sample 2D array 
plt.imshow(X, cmap="gray") 
plt.show() 

How can I do that?

0

There are 0 answers