[color=]import
numpy
[color=]as
np
[color=]import
matplotlib.pyplot
[color=]as
plt
result=np.load(
[color=]'result.npy'
)
(result.shape)
result=result.reshape(
[color=]384000
,
[color=]1600
)
plt.figure(
dpi
=
[color=]300
,
figsize
=(
[color=]10
,
[color=]10
))
plt.imshow(result[
[color=]800
:
[color=]1600
,:].T,
cmap
=
[color=]"Set1"
,
aspect
=
[color=]'auto'
)
plt.colorbar().ax.set_title(
[color=]'class'
)
plt.xlabel(
[color=]'Trace number'
)
plt.ylabel(
[color=]'Time(ms)'
)
plt.show()
错误:Error: failed to send plot to http://127.0.0.1:63342Traceback (most recent call last): File "C:\Program Files\JetBrains\PyCharm 2022.1\plugins\python\helpers\pycharm_display\datalore\display\display_.py", line 76, in _send_display_message urllib_request.urlopen(url, buffer) File "C:\Users\zhoushao\.conda\envs\pytorch11-py39\lib\urllib\request.py", line 214, in urlopen return opener.open(url, data, timeout) File "C:\Users\zhoushao\.conda\envs\pytorch11-py39\lib\urllib\request.py", line 523, in open response = meth(req, response) File "C:\Users\zhoushao\.conda\envs\pytorch11-py39\lib\urllib\request.py", line 632, in http_response response = self.parent.error( File "C:\Users\zhoushao\.conda\envs\pytorch11-py39\lib\urllib\request.py", line 561, in error return self._call_chain(*args) File "C:\Users\zhoushao\.conda\envs\pytorch11-py39\lib\urllib\request.py", line 494, in _call_chain result = func(*args) File "C:\Users\zhoushao\.conda\envs\pytorch11-py39\lib\urllib\request.py", line 641, in http_error_default raise HTTPError(req.full_url, code, msg, hdrs, fp)urllib.error.HTTPError: HTTP Error 500: Internal Server ErrorDuring handling of the above exception, another exception occurred:Traceback (most recent call last): File "C:\Program Files\JetBrains\PyCharm 2022.1\plugins\python\helpers\pycharm_display\datalore\display\display_.py", line 60, in try_empty_proxy urllib_request.urlopen(url, buffer) File "C:\Users\zhoushao\.conda\envs\pytorch11-py39\lib\urllib\request.py", line 214, in urlopen return opener.open(url, data, timeout) File "C:\Users\zhoushao\.conda\envs\pytorch11-py39\lib\urllib\request.py", line 523, in open response = meth(req, response) File "C:\Users\zhoushao\.conda\envs\pytorch11-py39\lib\urllib\request.py", line 632, in http_response response = self.parent.error( File "C:\Users\zhoushao\.conda\envs\pytorch11-py39\lib\urllib\request.py", line 561, in error return self._call_chain(*args) File "C:\Users\zhoushao\.conda\envs\pytorch11-py39\lib\urllib\request.py", line 494, in _call_chain result = func(*args) File "C:\Users\zhoushao\.conda\envs\pytorch11-py39\lib\urllib\request.py", line 641, in http_error_default raise HTTPError(req.full_url, code, msg, hdrs, fp)urllib.error.HTTPError: HTTP Error 500: Internal Server ErrorProcess finished with exit code 0
[color=]