Results visualization
(true, preds=None, name='./pic/test.pdf')
| 95 | |
| 96 | |
| 97 | def visual(true, preds=None, name='./pic/test.pdf'): |
| 98 | """ |
| 99 | Results visualization |
| 100 | """ |
| 101 | plt.figure() |
| 102 | plt.plot(true, label='GroundTruth', linewidth=2) |
| 103 | if preds is not None: |
| 104 | plt.plot(preds, label='Prediction', linewidth=2) |
| 105 | plt.legend() |
| 106 | plt.savefig(name, bbox_inches='tight') |