Skip to content

Commit

Permalink
Update notebook examples for 1.1.1 (#43)
Browse files Browse the repository at this point in the history
  • Loading branch information
karolzak authored Mar 15, 2022
1 parent 62689d7 commit 2558875
Showing 1 changed file with 20 additions and 13 deletions.
33 changes: 20 additions & 13 deletions notebooks/gear-images-examples.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -118,7 +118,7 @@
"outputs": [],
"source": [
"print('Downloading the data into `datasets` folder..')\n",
"url = 'https://privdatastorage.blob.core.windows.net/github/ipyplot/gear_images.zip'\n",
"url = 'https://privdatastorage.blob.core.windows.net/github/ipyplot/gear_images.zip?sp=r&st=2022-03-15T07:56:45Z&se=2030-03-15T15:56:45Z&spr=https&sv=2020-08-04&sr=b&sig=%2BywohgAXA2E02DSVghZzHudlyvmM9kFRDydAfwtC9g8%3D'\n",
"urllib.request.urlretrieve(url, datasets_dir + zip_filename)\n",
"print(\"Done!\")"
]
Expand Down Expand Up @@ -242,7 +242,7 @@
},
"outputs": [],
"source": [
"ipyplot.plot_class_tabs(images, labels, max_imgs_per_tab=5, img_width=150)"
"ipyplot.plot_class_tabs(images, labels, max_imgs_per_tab=10, img_width=150)"
]
},
{
Expand Down Expand Up @@ -282,7 +282,7 @@
"\n",
"images_np = np.asarray(images)\n",
"\n",
"ipyplot.plot_images(images_np, max_images=5)"
"ipyplot.plot_images(images_np, max_images=10)"
]
},
{
Expand Down Expand Up @@ -310,7 +310,7 @@
"images_df['images'] = images\n",
"images_df['labels'] = labels\n",
"\n",
"ipyplot.plot_images(images_df['images'], max_images=5)"
"ipyplot.plot_images(images_df['images'], max_images=7)"
]
},
{
Expand Down Expand Up @@ -352,7 +352,7 @@
"\n",
"images_pil = [Image.open(image) for image in images]\n",
"\n",
"ipyplot.plot_images(images_pil, max_images=5)"
"ipyplot.plot_images(images_pil, max_images=10)"
]
},
{
Expand All @@ -377,7 +377,7 @@
"\n",
"images_np = [np.asarray(image) for image in images_pil]\n",
"\n",
"ipyplot.plot_images(images_np, max_images=5)"
"ipyplot.plot_images(images_np, max_images=10)"
]
},
{
Expand Down Expand Up @@ -492,7 +492,7 @@
"outputs": [],
"source": [
"ipyplot.plot_class_tabs(\n",
" images, labels, max_imgs_per_tab=5, tabs_order=labels_list_filtered\n",
" images, labels, max_imgs_per_tab=7, tabs_order=labels_list_filtered\n",
")"
]
},
Expand Down Expand Up @@ -535,14 +535,14 @@
"end_time": "2020-10-20T19:38:37.022119Z",
"start_time": "2020-10-20T19:38:36.798582Z"
},
"scrolled": true
"scrolled": false
},
"outputs": [],
"source": [
"ignore_list = [\"boots\", \"axes\", \"helmets\", \"insulated_jackets\", \"hardshell_jackets\", \"tents\"]\n",
"\n",
"ipyplot.plot_class_representations(\n",
" images, labels, img_width=100, ignore_labels=ignore_list\n",
" images, labels, img_width=150, ignore_labels=ignore_list\n",
")"
]
},
Expand Down Expand Up @@ -594,15 +594,22 @@
},
"outputs": [],
"source": [
"ipyplot.plot_images(images, max_images=5, force_b64=True)"
"ipyplot.plot_images(images, max_images=8, force_b64=True)"
]
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {},
"outputs": [],
"source": []
}
],
"metadata": {
"kernelspec": {
"display_name": "Python [conda env:ipyplot_env] *",
"display_name": "Python [conda env:kaggle]",
"language": "python",
"name": "conda-env-ipyplot_env-py"
"name": "conda-env-kaggle-py"
},
"language_info": {
"codemirror_mode": {
Expand All @@ -614,7 +621,7 @@
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
"version": "3.7.0"
"version": "3.7.6"
}
},
"nbformat": 4,
Expand Down

0 comments on commit 2558875

Please sign in to comment.