Skip to content

Commit

Permalink
Place a system metadata stamp on readme chart (#405)
Browse files Browse the repository at this point in the history
  • Loading branch information
scotts authored Nov 20, 2024
1 parent 789cead commit fd4c288
Show file tree
Hide file tree
Showing 4 changed files with 423 additions and 409 deletions.
12 changes: 10 additions & 2 deletions benchmarks/decoders/benchmark_decoders_library.py
Original file line number Diff line number Diff line change
Expand Up @@ -444,11 +444,11 @@ def retrieve_videos(urls_and_dest_paths):
urllib.request.urlretrieve(url, path)


def plot_data(df_data, plot_path):
def plot_data(json_data, plot_path):
plt.rcParams["font.size"] = 18

# Creating the DataFrame
df = pd.DataFrame(df_data)
df = pd.DataFrame(json_data["experiments"])

# Sorting by video, type, and frame_count
df_sorted = df.sort_values(by=["video", "type", "frame_count"])
Expand Down Expand Up @@ -518,6 +518,14 @@ def plot_data(df_data, plot_path):
for col in range(video_type_combinations[unique_videos[row]], max_combinations):
fig.delaxes(axes[row, col])

plt.gcf().text(
0.005,
0.87,
"\n".join([f"{k}: {v}" for k, v in json_data["system_metadata"].items()]),
fontsize=11,
bbox=dict(facecolor="white"),
)

# Adjust layout to avoid overlap
plt.tight_layout()

Expand Down
Binary file modified benchmarks/decoders/benchmark_readme_chart.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading

0 comments on commit fd4c288

Please sign in to comment.