You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This seems to be related to the other plot issues (#10) but I can't fix.
Attached screenshot shows the error.
Also, I inserted the print of the data[] array to help me resolve another issue. It seems that a redirect of the output in PowerShell borks the formatting. I think there's a way in PS to fix it, but I just switched to cmd instead. In PS, the output is formatted into lines, and that formatting is carried into the file, making the resulting data[] a list of lists, one list for each line.
Python 3.10.0
numpy 1.21.3
matplotlib 3.4.3
The text was updated successfully, but these errors were encountered:
Well, I seemed to have borked things myself. I re-ran the PS capture of output & it came out the way it should. But, this time I get a different error from the one above. And it's the same error for both exports. A real WTF moment. Sorry.
Now, I did have to change the Unicode setting from UTF-16 to UTF-8, which is my Windows 10 Pro system. I know I've seen commentary around about Win 10 being the former, but mine was CP1252 until I enabled the beta option to switch to `UTF-8'. This is
Edition Windows 10 Pro
Version 21H1
Installed on 9/4/2021
OS build 19043.1288
The "latest and greatest" according to MS. :-\
I wonder if you can just use sys.stdin.encoding to get the necessary value.
C:\Users\micha\Dropbox\src\fortran\fortran-basics
{micha} [8] --> .\plot_water_height_multipanel.py .\output-ps.txt
Traceback (most recent call last):
File "C:\Users\micha\Dropbox\src\fortran\fortran-basics\plot_water_height_multipanel.py", line 44, in <module>
ax.plot(x, h[time_steps[n], :], "b-")
IndexError: index 25 is out of bounds for axis 0 with size 1
Hi @nyambol, sorry for the delay. I just looked at the files and they seem fine (they're exactly the same on my end). I was also able to plot them with the Python script. Unfortunately I don't have a Windows computer. Are you still having issues with this?
This seems to be related to the other plot issues (#10) but I can't fix.
Attached screenshot shows the error.
Also, I inserted the print of the
data[]
array to help me resolve another issue. It seems that a redirect of the output in PowerShell borks the formatting. I think there's a way in PS to fix it, but I just switched tocmd
instead. In PS, the output is formatted into lines, and that formatting is carried into the file, making the resultingdata[]
a list of lists, one list for each line.The text was updated successfully, but these errors were encountered: