Skip to content
Snippets Groups Projects
Commit 1b5d2905 authored by Dennis Noll's avatar Dennis Noll
Browse files

[plotting] init figure_dict

parent 0f2bcbbe
No related branches found
No related tags found
No related merge requests found
......@@ -129,10 +129,15 @@ def plot_histories(history_csv_path, path, cut=None, roll=1):
plt.close("all")
def plot_dict(importance, path="tmp.pdf"):
fig = plt.figure(figsize=(8, len(importance) / 3))
plt.barh(*zip(*importance.items()))
def figure_dict(d):
fig = plt.figure(figsize=(8, len(d) / 3))
plt.barh(*zip(*d.items()))
fig.tight_layout()
return fig
def plot_dict(d, path="tmp.pdf"):
fig = figure_dict(d)
plt.savefig(path)
plt.close("all")
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment