Unable to generate contour plot with NaN values in z (Plotly 5.6 and Plotly 5.7)

I am trying to make a contour plot (no fill, contours_coloring = ‘lines’) for a matrix of size 350x550. There are several hundred NaN values in the matrix and I am not able to generate a figure with this matrix as is. I’ve tried rendering it in a browser, saving it as a html with open default set to true and rendering it as a static image. For the last case, I get an error 525 and for the first two cases the figure is not generated at all. The figure is generated in all cases if I replace the NaNs with 0s but the contour is very messed up.

Any help is appreciated.

Edit: I am able to generate heatmaps with the exact same dataset no problem. It looks the way I expect it to. Same with a 3-D surface. It’s just the contour plot that has an issue.

Hello, are there any updates on this? Have not heard anything from the mods