Skip to content

Commit

Permalink
[#31] Update docs screengrabs
Browse files Browse the repository at this point in the history
  • Loading branch information
jaimervq committed Jul 27, 2024
1 parent a99b34c commit d678252
Show file tree
Hide file tree
Showing 9 changed files with 1 addition and 42 deletions.
3 changes: 1 addition & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -265,5 +265,4 @@ Automatically generated once a month
![](docs/analytics/recent_usage.png)
![](docs/analytics/most_used.png)
![](docs/analytics/errored.png)
![](docs/analytics/failed.png)
![](docs/analytics/slowest.png)
![](docs/analytics/failed.png)
40 changes: 0 additions & 40 deletions analytics/analytics.py
Original file line number Diff line number Diff line change
Expand Up @@ -167,46 +167,6 @@ def process_analytics():
fig.tight_layout()
fig.savefig(graph_file)

# Exec times ---------------------------------------
res = make_query_aggregation(
[
{
"$match": {
"$nor": [
{"class_name": re.compile(".*TimedNode")},
{"class_name": re.compile(".*StartFile")},
],
"IS_CONTEXT": {"$ne": True},
}
},
{
"$group": {
"_id": "$class_name",
"average_time": {"$avg": "$execution_time"},
}
},
{"$sort": {"average_time": -1}},
{"$limit": 10},
]
)

if res:
df = pl.DataFrame(list(res))

node_names = df["_id"].tolist()
avg_time = df["average_time"].tolist()

fig, ax = plt.subplots(figsize=(10, 7))
ax.barh(node_names, avg_time)
ax.set_xlabel("Average execution time (s)")
ax.set_ylabel("Node class")
ax.invert_yaxis()
ax.set_title("Top 10 slowest nodes")

graph_file = os.path.join(root_dir_path, "../docs/analytics", "slowest.png")
fig.tight_layout()
fig.savefig(graph_file)

# Last errored ---------------------------------------
res = make_query_aggregation(
[
Expand Down
Binary file removed docs/analytics/slowest.png
Binary file not shown.
Binary file modified docs/context.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified docs/ctx_grab.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified docs/exec_1.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified docs/exec_2.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified docs/start_node_manual.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified docs/start_nodes.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit d678252

Please sign in to comment.