fix sub-process error in thread

Former-commit-id: 3448ad43d05301b12a19a02c1cc23d7b0ee525c3
This commit is contained in:
hiyouga
2024-03-03 15:04:35 +08:00
parent 77ab9457ed
commit f4f71f2797
2 changed files with 5 additions and 4 deletions

View File

@@ -46,8 +46,8 @@ def plot_loss(save_dictionary: os.PathLike, keys: Optional[List[str]] = ["loss"]
continue
plt.figure()
plt.plot(steps, metrics, alpha=0.4, label="original")
plt.plot(steps, smooth(metrics), label="smoothed")
plt.plot(steps, metrics, color="#1f77b4", alpha=0.4, label="original")
plt.plot(steps, smooth(metrics), color="#1f77b4", label="smoothed")
plt.title("training {} of {}".format(key, save_dictionary))
plt.xlabel("step")
plt.ylabel(key)