Skip to content

Commit 0143720

Browse files
committed
Pushing the docs to dev/ for branch: main, commit e54a077f2d17f61c7f21404226dba04585da6a44
1 parent 6a3d743 commit 0143720

File tree

102 files changed

+50240
-50201
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

102 files changed

+50240
-50201
lines changed

dev/_downloads/198ad5d07740cb53545df898265e9ffe/02_text_with_string_encoders.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -295,6 +295,7 @@ def plot_performance_tradeoff(results):
295295
c="k",
296296
capsize=2,
297297
)
298+
ax.set_xscale("log")
298299

299300
ax.set_xlabel("Time to fit (seconds)")
300301
ax.set_ylabel("ROC AUC")
@@ -306,8 +307,8 @@ def plot_performance_tradeoff(results):
306307
xytext=(8.5, 0.90),
307308
arrowprops=dict(arrowstyle="->", mutation_scale=15),
308309
)
309-
ax.text(8, 0.86, "Best time / \nperformance trade-off")
310-
ax.legend(bbox_to_anchor=(1, 0.3))
310+
ax.text(5.8, 0.86, "Best time / \nperformance trade-off")
311+
ax.legend(bbox_to_anchor=(1.02, 0.3))
311312
plt.show()
312313

313314

Binary file not shown.
Binary file not shown.
0 Bytes
Binary file not shown.

dev/_downloads/32eb7122d28304b1f0e44f3a61f9889b/02_text_with_string_encoders.ipynb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -166,7 +166,7 @@
166166
},
167167
"outputs": [],
168168
"source": [
169-
"def plot_performance_tradeoff(results):\n fig, ax = plt.subplots(figsize=(5, 4), dpi=200)\n markers = [\"s\", \"o\", \"^\", \"x\"]\n for idx, (name, result) in enumerate(results):\n ax.scatter(\n result[\"fit_time\"],\n result[\"test_score\"],\n label=name,\n marker=markers[idx],\n )\n mean_fit_time = np.mean(result[\"fit_time\"])\n mean_score = np.mean(result[\"test_score\"])\n ax.scatter(\n mean_fit_time,\n mean_score,\n color=\"k\",\n marker=markers[idx],\n )\n std_fit_time = np.std(result[\"fit_time\"])\n std_score = np.std(result[\"test_score\"])\n ax.errorbar(\n x=mean_fit_time,\n y=mean_score,\n yerr=std_score,\n fmt=\"none\",\n c=\"k\",\n capsize=2,\n )\n ax.errorbar(\n x=mean_fit_time,\n y=mean_score,\n xerr=std_fit_time,\n fmt=\"none\",\n c=\"k\",\n capsize=2,\n )\n\n ax.set_xlabel(\"Time to fit (seconds)\")\n ax.set_ylabel(\"ROC AUC\")\n ax.set_title(\"Prediction performance / training time trade-off\")\n\n ax.annotate(\n \"\",\n xy=(1.5, 0.98),\n xytext=(8.5, 0.90),\n arrowprops=dict(arrowstyle=\"->\", mutation_scale=15),\n )\n ax.text(8, 0.86, \"Best time / \\nperformance trade-off\")\n ax.legend(bbox_to_anchor=(1, 0.3))\n plt.show()\n\n\nplot_performance_tradeoff(results)"
169+
"def plot_performance_tradeoff(results):\n fig, ax = plt.subplots(figsize=(5, 4), dpi=200)\n markers = [\"s\", \"o\", \"^\", \"x\"]\n for idx, (name, result) in enumerate(results):\n ax.scatter(\n result[\"fit_time\"],\n result[\"test_score\"],\n label=name,\n marker=markers[idx],\n )\n mean_fit_time = np.mean(result[\"fit_time\"])\n mean_score = np.mean(result[\"test_score\"])\n ax.scatter(\n mean_fit_time,\n mean_score,\n color=\"k\",\n marker=markers[idx],\n )\n std_fit_time = np.std(result[\"fit_time\"])\n std_score = np.std(result[\"test_score\"])\n ax.errorbar(\n x=mean_fit_time,\n y=mean_score,\n yerr=std_score,\n fmt=\"none\",\n c=\"k\",\n capsize=2,\n )\n ax.errorbar(\n x=mean_fit_time,\n y=mean_score,\n xerr=std_fit_time,\n fmt=\"none\",\n c=\"k\",\n capsize=2,\n )\n ax.set_xscale(\"log\")\n\n ax.set_xlabel(\"Time to fit (seconds)\")\n ax.set_ylabel(\"ROC AUC\")\n ax.set_title(\"Prediction performance / training time trade-off\")\n\n ax.annotate(\n \"\",\n xy=(1.5, 0.98),\n xytext=(8.5, 0.90),\n arrowprops=dict(arrowstyle=\"->\", mutation_scale=15),\n )\n ax.text(5.8, 0.86, \"Best time / \\nperformance trade-off\")\n ax.legend(bbox_to_anchor=(1.02, 0.3))\n plt.show()\n\n\nplot_performance_tradeoff(results)"
170170
]
171171
},
172172
{
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.

0 commit comments

Comments
 (0)