{ "cells": [ { "cell_type": "markdown", "source": [ "# Trinket! Stable Inversion\n", "A cheap alternative to finetuning stable diffusion, by [crumb](https://twitter.com/aicrumb)\n", "\n", "Finetunes the embedding layer like Textual-Inversion does, but on CLIP Text/Image pairs instead of reconstruction loss from Stable Diffusion. Lower memory requirements + (sometimes) faster than finetuning the traditional way." ], "metadata": { "id": "mSXDq5-qTSF6" }, "id": "mSXDq5-qTSF6" }, { "cell_type": "code", "source": [ "!pip install git+https://github.com/openai/CLIP -q\n", "!pip install bitsandbytes -q" ], "metadata": { "id": "yB-XeS51NmI2" }, "id": "yB-XeS51NmI2", "execution_count": 1, "outputs": [] }, { "cell_type": "code", "source": [ "import bitsandbytes as bnb\n", "import torchvision\n", "from torchvision import transforms\n", "from tqdm.auto import *\n", "from torch import nn, optim\n", "from torch.nn import functional as F\n", "from PIL import Image\n", "import requests\n", "from io import BytesIO\n", "import torch\n", "import random\n", "import clip\n", "import pandas as pd" ], "metadata": { "id": "x1OogszooEi6", "colab": { "base_uri": "https://localhost:8080/" }, "outputId": "a55a628d-aafc-407e-a2a9-fb03b8a0896a" }, "id": "x1OogszooEi6", "execution_count": 2, "outputs": [ { "output_type": "stream", "name": "stdout", "text": [ "\n", "===================================BUG REPORT===================================\n", "Welcome to bitsandbytes. For bug reports, please submit your error trace to: https://github.com/TimDettmers/bitsandbytes/issues\n", "For effortless bug reporting copy-paste your error into this form: https://docs.google.com/forms/d/e/1FAIpQLScPB8emS3Thkp66nvqwmjTEgxp8Y9ufuWTzFyr9kJ5AoI47dQ/viewform?usp=sf_link\n", "================================================================================\n", "CUDA_SETUP: WARNING! libcudart.so not found in any environmental path. Searching /usr/local/cuda/lib64...\n", "CUDA SETUP: CUDA runtime path found: /usr/local/cuda/lib64/libcudart.so\n", "CUDA SETUP: Highest compute capability among GPUs detected: 7.5\n", "CUDA SETUP: Detected CUDA version 111\n", "CUDA SETUP: Loading binary /usr/local/lib/python3.7/dist-packages/bitsandbytes/libbitsandbytes_cuda111.so...\n" ] }, { "output_type": "stream", "name": "stderr", "text": [ "/usr/local/lib/python3.7/dist-packages/bitsandbytes/cuda_setup/paths.py:99: UserWarning: /usr/lib64-nvidia did not contain libcudart.so as expected! Searching further paths...\n", " f'{candidate_env_vars[\"LD_LIBRARY_PATH\"]} did not contain '\n", "/usr/local/lib/python3.7/dist-packages/bitsandbytes/cuda_setup/paths.py:21: UserWarning: WARNING: The following directories listed in your path were found to be non-existent: {PosixPath('{\"kernelManagerProxyPort\"'), PosixPath('\"/usr/local/bin/dap_multiplexer\",\"enableLsp\"'), PosixPath('\"172.28.0.3\",\"jupyterArgs\"'), PosixPath('[\"--ip=172.28.0.2\"],\"debugAdapterMultiplexerPath\"'), PosixPath('true}'), PosixPath('6000,\"kernelManagerProxyHost\"')}\n", " \"WARNING: The following directories listed in your path were found to \"\n", "/usr/local/lib/python3.7/dist-packages/bitsandbytes/cuda_setup/paths.py:21: UserWarning: WARNING: The following directories listed in your path were found to be non-existent: {PosixPath('/env/python')}\n", " \"WARNING: The following directories listed in your path were found to \"\n", "/usr/local/lib/python3.7/dist-packages/bitsandbytes/cuda_setup/paths.py:21: UserWarning: WARNING: The following directories listed in your path were found to be non-existent: {PosixPath('module'), PosixPath('//ipykernel.pylab.backend_inline')}\n", " \"WARNING: The following directories listed in your path were found to \"\n" ] } ] }, { "cell_type": "code", "execution_count": 3, "id": "22b6861e-289f-4779-bbf1-40bfd1327823", "metadata": { "colab": { "base_uri": "https://localhost:8080/" }, "id": "22b6861e-289f-4779-bbf1-40bfd1327823", "outputId": "fd96d25d-8cbf-43d2-8d5b-983856bf2a3a" }, "outputs": [ { "output_type": "stream", "name": "stdout", "text": [ "Loaded CLIP\n" ] } ], "source": [ "# the stable diffusion model uses L/14 by default\n", "clip_model, _ = clip.load(\"ViT-L/14\", jit=False)\n", "clip_model = clip_model.cuda()\n", "print(\"Loaded CLIP\")" ] }, { "cell_type": "code", "execution_count": 4, "id": "eaa9bde8-3fdd-48df-aa36-8b88cec285be", "metadata": { "id": "eaa9bde8-3fdd-48df-aa36-8b88cec285be" }, "outputs": [], "source": [ "bs = 16 # need a large batch size for the contrastive loss to work properly\n", "steps = 64\n", "epochs = 4\n", "lr = 1e-3" ] }, { "cell_type": "code", "execution_count": 5, "id": "0667d187-2c3e-40b8-a2fd-b408d5f144c5", "metadata": { "colab": { "base_uri": "https://localhost:8080/", "height": 206 }, "id": "0667d187-2c3e-40b8-a2fd-b408d5f144c5", "outputId": "b8f6056a-c2ac-4b89-e222-0d47705617e9" }, "outputs": [ { "output_type": "execute_result", "data": { "text/plain": [ " Unnamed: 0 url \\\n", "0 0 https://cdn.donmai.us/original/51/bb/51bb44d69... \n", "1 1 https://cdn.donmai.us/original/4f/8e/4f8e5eaba... \n", "2 2 https://cdn.donmai.us/original/c8/54/c85428d89... \n", "3 3 https://cdn.donmai.us/original/e9/fc/e9fcc788e... \n", "4 4 https://cdn.donmai.us/original/8a/63/8a639d21b... \n", "\n", " prompt \n", "0 genshin_impact boo_tao_(genshin_impact) hu_tao... \n", "1 genshin_impact arlecchino_(genshin_impact) cap... \n", "2 genshin_impact fischl_(ein_immernachtstraum)_(... \n", "3 genshin_impact eula_(genshin_impact) 1girl :o ... \n", "4 genshin_impact kuki_shinobu 1girl breasts brid... " ], "text/html": [ "\n", "
\n", "
\n", "
\n", "\n", "\n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", " \n", "
Unnamed: 0urlprompt
00https://cdn.donmai.us/original/51/bb/51bb44d69...genshin_impact boo_tao_(genshin_impact) hu_tao...
11https://cdn.donmai.us/original/4f/8e/4f8e5eaba...genshin_impact arlecchino_(genshin_impact) cap...
22https://cdn.donmai.us/original/c8/54/c85428d89...genshin_impact fischl_(ein_immernachtstraum)_(...
33https://cdn.donmai.us/original/e9/fc/e9fcc788e...genshin_impact eula_(genshin_impact) 1girl :o ...
44https://cdn.donmai.us/original/8a/63/8a639d21b...genshin_impact kuki_shinobu 1girl breasts brid...
\n", "
\n", " \n", " \n", " \n", "\n", " \n", "
\n", "
\n", " " ] }, "metadata": {}, "execution_count": 5 } ], "source": [ "# ultimately you just need >1000 prompt+url pairs in lists named prompts and urls, however you load it is fine\n", "# this is how i scraped them so this is how i load them\n", "# you can scrape danbooru/safebooru/others with pybooru with this script from waifu-diffusion https://github.com/harubaru/waifu-diffusion/blob/main/danbooru_data/scrape.py\n", "df = pd.read_csv(\"/content/genshin.csv\")\n", "prompts = df['prompt']#[:steps*bs]\n", "urls = df['url']#[:steps*bs\n", "df.head()" ] }, { "cell_type": "code", "source": [ "print(len(prompts))" ], "metadata": { "colab": { "base_uri": "https://localhost:8080/" }, "id": "6lYQYqKEZKhv", "outputId": "7d26b946-ce1e-41ed-abaf-a4efed5d02cc" }, "id": "6lYQYqKEZKhv", "execution_count": 6, "outputs": [ { "output_type": "stream", "name": "stdout", "text": [ "1200\n" ] } ] }, { "cell_type": "code", "execution_count": 7, "id": "12fce080-73f3-430f-ba2c-99f265316b66", "metadata": { "id": "12fce080-73f3-430f-ba2c-99f265316b66" }, "outputs": [], "source": [ "clip_model.token_embedding.weight.requires_grad = True\n", "# opt = optim.Adam([clip_model.token_embedding.weight], lr)\n", "opt = bnb.optim.AdamW8bit([clip_model.token_embedding.weight], lr)" ] }, { "cell_type": "code", "execution_count": 8, "id": "9a4b1696-a8d9-4eea-a8e0-ba372d450619", "metadata": { "id": "9a4b1696-a8d9-4eea-a8e0-ba372d450619" }, "outputs": [], "source": [ "# functions from another project of mine that's a bit messy\n", "def fix_to_224(pil_image):\n", " width, height = pil_image.size\n", " if width < height:\n", " new_width = 224\n", " new_height = int(new_width * height / width)\n", " else:\n", " new_height = 224\n", " new_width = int(new_height * width / height)\n", " return pil_image.resize((new_width, new_height))\n", "def to_tensor_and_center_crop(pil_image):\n", " tensor = torchvision.transforms.functional.to_tensor(pil_image)\n", " center_crop = torchvision.transforms.functional.center_crop(tensor, (224, 224))\n", " return center_crop\n", "def fix(img):\n", " return to_tensor_and_center_crop(fix_to_224(img))\n", "\n", "iter_prompts = iter(prompts)\n", "iter_urls = iter(urls)\n", "def get_batch(size=8, step=1, steps_per_epoch=128, epoch=1, total_epochs=1):\n", " to_tensor = transforms.ToTensor()\n", " x = []\n", " y = []\n", " total_steps = total_epochs*steps_per_epoch\n", " current_fraction = (epoch*steps_per_epoch-steps_per_epoch+step) / total_steps\n", "\n", " while len(x) < size:\n", " # uncomment these and space the big block right one tab\n", " # if you're using a set that might have dead urls\n", " try:\n", " url = next(iter_urls)\n", " response = requests.get(url)\n", " img = Image.open(BytesIO(response.content))\n", " img = img.convert(\"RGB\")\n", " img = fix(img)\n", " x.append(img.unsqueeze(0))\n", "\n", " p = next(iter_prompts)\n", "\n", " # comment out these lines if you aren't using danbooru tags\n", " p = p.split(\" \")\n", " random.shuffle(p)\n", " if current_fraction > 0.5: # halfway through training, start dropping half of the tags\n", " p = p[:len(p)//2]\n", " if current_fraction > 0.75: # halfway through training, start dropping half of the tags\n", " p = p[:len(p)//2]\n", " p = \" \".join(p)\n", " y.append(p)\n", " except KeyboardInterrupt:\n", " print('Interrupted')\n", " break\n", " except:\n", " pass\n", " \n", " x = torch.cat(x, 0)\n", " x = clip_model.encode_image(x.cuda())\n", " \n", " y = clip.tokenize(y, truncate=True)\n", " y = clip_model.encode_text(y.cuda())\n", " return x, y" ] }, { "cell_type": "code", "execution_count": null, "id": "203637dd-441e-4b43-944d-48ffa126e826", "metadata": { "colab": { "base_uri": "https://localhost:8080/", "height": 182, "referenced_widgets": [ "cfab11c900c44070b2dc032034b9a65d", "edf50d7b6e8b475abd9e1ebae7778aba", "af697a5f975c405190c54d2a349b551c", "1953f85f00e04cb4bb95acadbb589b12", "d28248f12d834263a1605afed777077a", "1b255d9b51cb4dee82e1d14a506bf85e", "effd6703ac904650a7c02fbac19d1ce9", "f62a8b3dfedd4500b795e8a9e57ee4e1", "c2669c5874354798b33d7da9a5d8084d", "6b085d5276bf42c8b8e6a050de4730c9", "47347341d5a14564a25e52179187b218", "39487ee2262647a79ed05bd89413ec25", "37fd57a2be584e37aade4f200aca564e", "2daa2d8768f94963b4be13ee5108ec16", "41d52c3d2db543ac8654f2d79ea72f51", "cee7cfd5a46a4a86a048e84c9aa6df56", "365846f3939d49188dd2698ccb4a0c6d", "fa8cd1c1559248aeb8a920d6a1f7b8ca", "8d6f469af323498aae3b8c2fd2e4f7de", "a58aa5c526234c25bd330564a8631310", "355e7a4bac0f41d1a0a7aba831c1916b", "d8d127599a964af2b22957e7cadc3949", "94c994a72e6e47a581ef47eafc4f8621", "e2409e281b874665bbe830fc5843e4fe", "c980cbb0b5ba43378c84ea122829e70e", "08ab7aae4ac341909798caf190c84ada", "9decfef2a41f42f0a3b77dfaa3a02bac", "a0f24920a480438381da74562a7f7df1", "bc4723c3d801406b891f808c84e9e83b", "c464d7549104481a90f75f3e5b219189", "d9792cd6d5034352a3a9f2122bb5d9c0", "8a9c974907c74fe29b6a323df7df0d4d", "40ae1be859d74847b4f0944c4027e1cf" ] }, "id": "203637dd-441e-4b43-944d-48ffa126e826", "outputId": "4ea5f3da-86fa-4910-d919-fc1ef0d8f007" }, "outputs": [ { "output_type": "display_data", "data": { "text/plain": [ " 0%| | 0/4 [00:001:\n", " g = hf_hub_download(repo_id=stable_inversion, filename=\"token_embeddings.pt\")\n", " text_encoder.text_model.embeddings.token_embedding.weight = torch.load(g)\n", "```" ], "metadata": { "id": "tIKiCVkHkFET" }, "id": "tIKiCVkHkFET" } ], "metadata": { "kernelspec": { "display_name": "Python 3 (ipykernel)", "language": "python", "name": "python3" }, "language_info": { "codemirror_mode": { "name": "ipython", "version": 3 }, "file_extension": ".py", "mimetype": "text/x-python", "name": "python", "nbconvert_exporter": "python", "pygments_lexer": "ipython3", "version": "3.10.4" }, "colab": { "provenance": [], "collapsed_sections": [] }, "accelerator": "GPU", "widgets": { "application/vnd.jupyter.widget-state+json": { "cfab11c900c44070b2dc032034b9a65d": { "model_module": "@jupyter-widgets/controls", "model_name": "HBoxModel", "model_module_version": "1.5.0", "state": { "_dom_classes": [], "_model_module": "@jupyter-widgets/controls", "_model_module_version": "1.5.0", "_model_name": "HBoxModel", "_view_count": null, "_view_module": "@jupyter-widgets/controls", "_view_module_version": "1.5.0", "_view_name": "HBoxView", "box_style": "", "children": [ "IPY_MODEL_edf50d7b6e8b475abd9e1ebae7778aba", "IPY_MODEL_af697a5f975c405190c54d2a349b551c", "IPY_MODEL_1953f85f00e04cb4bb95acadbb589b12" ], "layout": "IPY_MODEL_d28248f12d834263a1605afed777077a" } }, "edf50d7b6e8b475abd9e1ebae7778aba": { "model_module": "@jupyter-widgets/controls", "model_name": "HTMLModel", "model_module_version": "1.5.0", "state": { "_dom_classes": [], "_model_module": "@jupyter-widgets/controls", "_model_module_version": "1.5.0", "_model_name": "HTMLModel", "_view_count": null, "_view_module": "@jupyter-widgets/controls", "_view_module_version": "1.5.0", "_view_name": "HTMLView", "description": "", "description_tooltip": null, "layout": "IPY_MODEL_1b255d9b51cb4dee82e1d14a506bf85e", "placeholder": "​", "style": "IPY_MODEL_effd6703ac904650a7c02fbac19d1ce9", "value": " 25%" } }, "af697a5f975c405190c54d2a349b551c": { "model_module": "@jupyter-widgets/controls", "model_name": "FloatProgressModel", "model_module_version": "1.5.0", "state": { "_dom_classes": [], "_model_module": "@jupyter-widgets/controls", "_model_module_version": "1.5.0", "_model_name": "FloatProgressModel", "_view_count": null, "_view_module": "@jupyter-widgets/controls", "_view_module_version": "1.5.0", "_view_name": "ProgressView", "bar_style": "", "description": "", "description_tooltip": null, "layout": "IPY_MODEL_f62a8b3dfedd4500b795e8a9e57ee4e1", "max": 4, "min": 0, "orientation": "horizontal", "style": "IPY_MODEL_c2669c5874354798b33d7da9a5d8084d", "value": 1 } }, "1953f85f00e04cb4bb95acadbb589b12": { "model_module": "@jupyter-widgets/controls", "model_name": "HTMLModel", "model_module_version": "1.5.0", "state": { "_dom_classes": [], "_model_module": "@jupyter-widgets/controls", "_model_module_version": "1.5.0", "_model_name": "HTMLModel", "_view_count": null, "_view_module": "@jupyter-widgets/controls", "_view_module_version": "1.5.0", "_view_name": "HTMLView", "description": "", "description_tooltip": null, "layout": "IPY_MODEL_6b085d5276bf42c8b8e6a050de4730c9", "placeholder": "​", "style": "IPY_MODEL_47347341d5a14564a25e52179187b218", "value": " 1/4 [10:02<30:08, 602.73s/it]" } }, "d28248f12d834263a1605afed777077a": { "model_module": "@jupyter-widgets/base", "model_name": "LayoutModel", "model_module_version": "1.2.0", "state": { "_model_module": "@jupyter-widgets/base", "_model_module_version": "1.2.0", "_model_name": "LayoutModel", "_view_count": null, "_view_module": "@jupyter-widgets/base", "_view_module_version": "1.2.0", "_view_name": "LayoutView", "align_content": null, "align_items": null, "align_self": null, "border": null, "bottom": null, "display": null, "flex": null, "flex_flow": null, "grid_area": null, "grid_auto_columns": null, "grid_auto_flow": null, "grid_auto_rows": null, "grid_column": null, "grid_gap": null, "grid_row": null, "grid_template_areas": null, "grid_template_columns": null, "grid_template_rows": null, "height": null, "justify_content": null, "justify_items": null, "left": null, "margin": null, "max_height": null, "max_width": null, "min_height": null, "min_width": null, "object_fit": null, "object_position": null, "order": null, "overflow": null, "overflow_x": null, "overflow_y": null, "padding": null, "right": null, "top": null, "visibility": null, "width": null } }, "1b255d9b51cb4dee82e1d14a506bf85e": { "model_module": "@jupyter-widgets/base", "model_name": "LayoutModel", "model_module_version": "1.2.0", "state": { "_model_module": "@jupyter-widgets/base", "_model_module_version": "1.2.0", "_model_name": "LayoutModel", "_view_count": null, "_view_module": "@jupyter-widgets/base", "_view_module_version": "1.2.0", "_view_name": "LayoutView", "align_content": null, "align_items": null, "align_self": null, "border": null, "bottom": null, "display": null, "flex": null, "flex_flow": null, "grid_area": null, "grid_auto_columns": null, "grid_auto_flow": null, "grid_auto_rows": null, "grid_column": null, "grid_gap": null, "grid_row": null, "grid_template_areas": null, "grid_template_columns": null, "grid_template_rows": null, "height": null, "justify_content": null, "justify_items": null, "left": null, "margin": null, "max_height": null, "max_width": null, "min_height": null, "min_width": null, "object_fit": null, "object_position": null, "order": null, "overflow": null, "overflow_x": null, "overflow_y": null, "padding": null, "right": null, "top": null, "visibility": null, "width": null } }, "effd6703ac904650a7c02fbac19d1ce9": { "model_module": "@jupyter-widgets/controls", "model_name": "DescriptionStyleModel", "model_module_version": "1.5.0", "state": { "_model_module": "@jupyter-widgets/controls", "_model_module_version": "1.5.0", "_model_name": "DescriptionStyleModel", "_view_count": null, "_view_module": "@jupyter-widgets/base", "_view_module_version": "1.2.0", "_view_name": "StyleView", "description_width": "" } }, "f62a8b3dfedd4500b795e8a9e57ee4e1": { "model_module": "@jupyter-widgets/base", "model_name": "LayoutModel", "model_module_version": "1.2.0", "state": { "_model_module": "@jupyter-widgets/base", "_model_module_version": "1.2.0", "_model_name": "LayoutModel", "_view_count": null, "_view_module": "@jupyter-widgets/base", "_view_module_version": "1.2.0", "_view_name": "LayoutView", "align_content": null, "align_items": null, "align_self": null, "border": null, "bottom": null, "display": null, "flex": null, "flex_flow": null, "grid_area": null, "grid_auto_columns": null, "grid_auto_flow": null, "grid_auto_rows": null, "grid_column": null, "grid_gap": null, "grid_row": null, "grid_template_areas": null, "grid_template_columns": null, "grid_template_rows": null, "height": null, "justify_content": null, "justify_items": null, "left": null, "margin": null, "max_height": null, "max_width": null, "min_height": null, "min_width": null, "object_fit": null, "object_position": null, "order": null, "overflow": null, "overflow_x": null, "overflow_y": null, "padding": null, "right": null, "top": null, "visibility": null, "width": null } }, "c2669c5874354798b33d7da9a5d8084d": { "model_module": "@jupyter-widgets/controls", "model_name": "ProgressStyleModel", "model_module_version": "1.5.0", "state": { "_model_module": "@jupyter-widgets/controls", "_model_module_version": "1.5.0", "_model_name": "ProgressStyleModel", "_view_count": null, "_view_module": "@jupyter-widgets/base", "_view_module_version": "1.2.0", "_view_name": "StyleView", "bar_color": null, "description_width": "" } }, "6b085d5276bf42c8b8e6a050de4730c9": { "model_module": "@jupyter-widgets/base", "model_name": "LayoutModel", "model_module_version": "1.2.0", "state": { "_model_module": "@jupyter-widgets/base", "_model_module_version": "1.2.0", "_model_name": "LayoutModel", "_view_count": null, "_view_module": "@jupyter-widgets/base", "_view_module_version": "1.2.0", "_view_name": "LayoutView", "align_content": null, "align_items": null, "align_self": null, "border": null, "bottom": null, "display": null, "flex": null, "flex_flow": null, "grid_area": null, "grid_auto_columns": null, "grid_auto_flow": null, "grid_auto_rows": null, "grid_column": null, "grid_gap": null, "grid_row": null, "grid_template_areas": null, "grid_template_columns": null, "grid_template_rows": null, "height": null, "justify_content": null, "justify_items": null, "left": null, "margin": null, "max_height": null, "max_width": null, "min_height": null, "min_width": null, "object_fit": null, "object_position": null, "order": null, "overflow": null, "overflow_x": null, "overflow_y": null, "padding": null, "right": null, "top": null, "visibility": null, "width": null } }, "47347341d5a14564a25e52179187b218": { "model_module": "@jupyter-widgets/controls", "model_name": "DescriptionStyleModel", "model_module_version": "1.5.0", "state": { "_model_module": "@jupyter-widgets/controls", "_model_module_version": "1.5.0", "_model_name": "DescriptionStyleModel", "_view_count": null, "_view_module": "@jupyter-widgets/base", "_view_module_version": "1.2.0", "_view_name": "StyleView", "description_width": "" } }, "39487ee2262647a79ed05bd89413ec25": { "model_module": "@jupyter-widgets/controls", "model_name": "HBoxModel", "model_module_version": "1.5.0", "state": { "_dom_classes": [], "_model_module": "@jupyter-widgets/controls", "_model_module_version": "1.5.0", "_model_name": "HBoxModel", "_view_count": null, "_view_module": "@jupyter-widgets/controls", "_view_module_version": "1.5.0", "_view_name": "HBoxView", "box_style": "", "children": [ "IPY_MODEL_37fd57a2be584e37aade4f200aca564e", "IPY_MODEL_2daa2d8768f94963b4be13ee5108ec16", "IPY_MODEL_41d52c3d2db543ac8654f2d79ea72f51" ], "layout": "IPY_MODEL_cee7cfd5a46a4a86a048e84c9aa6df56" } }, "37fd57a2be584e37aade4f200aca564e": { "model_module": "@jupyter-widgets/controls", "model_name": "HTMLModel", "model_module_version": "1.5.0", "state": { "_dom_classes": [], "_model_module": "@jupyter-widgets/controls", "_model_module_version": "1.5.0", "_model_name": "HTMLModel", "_view_count": null, "_view_module": "@jupyter-widgets/controls", "_view_module_version": "1.5.0", "_view_name": "HTMLView", "description": "", "description_tooltip": null, "layout": "IPY_MODEL_365846f3939d49188dd2698ccb4a0c6d", "placeholder": "​", "style": "IPY_MODEL_fa8cd1c1559248aeb8a920d6a1f7b8ca", "value": "0.277587890625: 100%" } }, "2daa2d8768f94963b4be13ee5108ec16": { "model_module": "@jupyter-widgets/controls", "model_name": "FloatProgressModel", "model_module_version": "1.5.0", "state": { "_dom_classes": [], "_model_module": "@jupyter-widgets/controls", "_model_module_version": "1.5.0", "_model_name": "FloatProgressModel", "_view_count": null, "_view_module": "@jupyter-widgets/controls", "_view_module_version": "1.5.0", "_view_name": "ProgressView", "bar_style": "success", "description": "", "description_tooltip": null, "layout": "IPY_MODEL_8d6f469af323498aae3b8c2fd2e4f7de", "max": 64, "min": 0, "orientation": "horizontal", "style": "IPY_MODEL_a58aa5c526234c25bd330564a8631310", "value": 64 } }, "41d52c3d2db543ac8654f2d79ea72f51": { "model_module": "@jupyter-widgets/controls", "model_name": "HTMLModel", "model_module_version": "1.5.0", "state": { "_dom_classes": [], "_model_module": "@jupyter-widgets/controls", "_model_module_version": "1.5.0", "_model_name": "HTMLModel", "_view_count": null, "_view_module": "@jupyter-widgets/controls", "_view_module_version": "1.5.0", "_view_name": "HTMLView", "description": "", "description_tooltip": null, "layout": "IPY_MODEL_355e7a4bac0f41d1a0a7aba831c1916b", "placeholder": "​", "style": "IPY_MODEL_d8d127599a964af2b22957e7cadc3949", "value": " 64/64 [10:02<00:00, 9.10s/it]" } }, "cee7cfd5a46a4a86a048e84c9aa6df56": { "model_module": "@jupyter-widgets/base", "model_name": "LayoutModel", "model_module_version": "1.2.0", "state": { "_model_module": "@jupyter-widgets/base", "_model_module_version": "1.2.0", "_model_name": "LayoutModel", "_view_count": null, "_view_module": "@jupyter-widgets/base", "_view_module_version": "1.2.0", "_view_name": "LayoutView", "align_content": null, "align_items": null, "align_self": null, "border": null, "bottom": null, "display": null, "flex": null, "flex_flow": null, "grid_area": null, "grid_auto_columns": null, "grid_auto_flow": null, "grid_auto_rows": null, "grid_column": null, "grid_gap": null, "grid_row": null, "grid_template_areas": null, "grid_template_columns": null, "grid_template_rows": null, "height": null, "justify_content": null, "justify_items": null, "left": null, "margin": null, "max_height": null, "max_width": null, "min_height": null, "min_width": null, "object_fit": null, "object_position": null, "order": null, "overflow": null, "overflow_x": null, "overflow_y": null, "padding": null, "right": null, "top": null, "visibility": null, "width": null } }, "365846f3939d49188dd2698ccb4a0c6d": { "model_module": "@jupyter-widgets/base", "model_name": "LayoutModel", "model_module_version": "1.2.0", "state": { "_model_module": "@jupyter-widgets/base", "_model_module_version": "1.2.0", "_model_name": "LayoutModel", "_view_count": null, "_view_module": "@jupyter-widgets/base", "_view_module_version": "1.2.0", "_view_name": "LayoutView", "align_content": null, "align_items": null, "align_self": null, "border": null, "bottom": null, "display": null, "flex": null, "flex_flow": null, "grid_area": null, "grid_auto_columns": null, "grid_auto_flow": null, "grid_auto_rows": null, "grid_column": null, "grid_gap": null, "grid_row": null, "grid_template_areas": null, "grid_template_columns": null, "grid_template_rows": null, "height": null, "justify_content": null, "justify_items": null, "left": null, "margin": null, "max_height": null, "max_width": null, "min_height": null, "min_width": null, "object_fit": null, "object_position": null, "order": null, "overflow": null, "overflow_x": null, "overflow_y": null, "padding": null, "right": null, "top": null, "visibility": null, "width": null } }, "fa8cd1c1559248aeb8a920d6a1f7b8ca": { "model_module": "@jupyter-widgets/controls", "model_name": "DescriptionStyleModel", "model_module_version": "1.5.0", "state": { "_model_module": "@jupyter-widgets/controls", "_model_module_version": "1.5.0", "_model_name": "DescriptionStyleModel", "_view_count": null, "_view_module": "@jupyter-widgets/base", "_view_module_version": "1.2.0", "_view_name": "StyleView", "description_width": "" } }, "8d6f469af323498aae3b8c2fd2e4f7de": { "model_module": "@jupyter-widgets/base", "model_name": "LayoutModel", "model_module_version": "1.2.0", "state": { "_model_module": "@jupyter-widgets/base", "_model_module_version": "1.2.0", "_model_name": "LayoutModel", "_view_count": null, "_view_module": "@jupyter-widgets/base", "_view_module_version": "1.2.0", "_view_name": "LayoutView", "align_content": null, "align_items": null, "align_self": null, "border": null, "bottom": null, "display": null, "flex": null, "flex_flow": null, "grid_area": null, "grid_auto_columns": null, "grid_auto_flow": null, "grid_auto_rows": null, "grid_column": null, "grid_gap": null, "grid_row": null, "grid_template_areas": null, "grid_template_columns": null, "grid_template_rows": null, "height": null, "justify_content": null, "justify_items": null, "left": null, "margin": null, "max_height": null, "max_width": null, "min_height": null, "min_width": null, "object_fit": null, "object_position": null, "order": null, "overflow": null, "overflow_x": null, "overflow_y": null, "padding": null, "right": null, "top": null, "visibility": null, "width": null } }, "a58aa5c526234c25bd330564a8631310": { "model_module": "@jupyter-widgets/controls", "model_name": "ProgressStyleModel", "model_module_version": "1.5.0", "state": { "_model_module": "@jupyter-widgets/controls", "_model_module_version": "1.5.0", "_model_name": "ProgressStyleModel", "_view_count": null, "_view_module": "@jupyter-widgets/base", "_view_module_version": "1.2.0", "_view_name": "StyleView", "bar_color": null, "description_width": "" } }, "355e7a4bac0f41d1a0a7aba831c1916b": { "model_module": "@jupyter-widgets/base", "model_name": "LayoutModel", "model_module_version": "1.2.0", "state": { "_model_module": "@jupyter-widgets/base", "_model_module_version": "1.2.0", "_model_name": "LayoutModel", "_view_count": null, "_view_module": "@jupyter-widgets/base", "_view_module_version": "1.2.0", "_view_name": "LayoutView", "align_content": null, "align_items": null, "align_self": null, "border": null, "bottom": null, "display": null, "flex": null, "flex_flow": null, "grid_area": null, "grid_auto_columns": null, "grid_auto_flow": null, "grid_auto_rows": null, "grid_column": null, "grid_gap": null, "grid_row": null, "grid_template_areas": null, "grid_template_columns": null, "grid_template_rows": null, "height": null, "justify_content": null, "justify_items": null, "left": null, "margin": null, "max_height": null, "max_width": null, "min_height": null, "min_width": null, "object_fit": null, "object_position": null, "order": null, "overflow": null, "overflow_x": null, "overflow_y": null, "padding": null, "right": null, "top": null, "visibility": null, "width": null } }, "d8d127599a964af2b22957e7cadc3949": { "model_module": "@jupyter-widgets/controls", "model_name": "DescriptionStyleModel", "model_module_version": "1.5.0", "state": { "_model_module": "@jupyter-widgets/controls", "_model_module_version": "1.5.0", "_model_name": "DescriptionStyleModel", "_view_count": null, "_view_module": "@jupyter-widgets/base", "_view_module_version": "1.2.0", "_view_name": "StyleView", "description_width": "" } }, "94c994a72e6e47a581ef47eafc4f8621": { "model_module": "@jupyter-widgets/controls", "model_name": "HBoxModel", "model_module_version": "1.5.0", "state": { "_dom_classes": [], "_model_module": "@jupyter-widgets/controls", "_model_module_version": "1.5.0", "_model_name": "HBoxModel", "_view_count": null, "_view_module": "@jupyter-widgets/controls", "_view_module_version": "1.5.0", "_view_name": "HBoxView", "box_style": "", "children": [ "IPY_MODEL_e2409e281b874665bbe830fc5843e4fe", "IPY_MODEL_c980cbb0b5ba43378c84ea122829e70e", "IPY_MODEL_08ab7aae4ac341909798caf190c84ada" ], "layout": "IPY_MODEL_9decfef2a41f42f0a3b77dfaa3a02bac" } }, "e2409e281b874665bbe830fc5843e4fe": { "model_module": "@jupyter-widgets/controls", "model_name": "HTMLModel", "model_module_version": "1.5.0", "state": { "_dom_classes": [], "_model_module": "@jupyter-widgets/controls", "_model_module_version": "1.5.0", "_model_name": "HTMLModel", "_view_count": null, "_view_module": "@jupyter-widgets/controls", "_view_module_version": "1.5.0", "_view_name": "HTMLView", "description": "", "description_tooltip": null, "layout": "IPY_MODEL_a0f24920a480438381da74562a7f7df1", "placeholder": "​", "style": "IPY_MODEL_bc4723c3d801406b891f808c84e9e83b", "value": "0.2724609375: 84%" } }, "c980cbb0b5ba43378c84ea122829e70e": { "model_module": "@jupyter-widgets/controls", "model_name": "FloatProgressModel", "model_module_version": "1.5.0", "state": { "_dom_classes": [], "_model_module": "@jupyter-widgets/controls", "_model_module_version": "1.5.0", "_model_name": "FloatProgressModel", "_view_count": null, "_view_module": "@jupyter-widgets/controls", "_view_module_version": "1.5.0", "_view_name": "ProgressView", "bar_style": "", "description": "", "description_tooltip": null, "layout": "IPY_MODEL_c464d7549104481a90f75f3e5b219189", "max": 64, "min": 0, "orientation": "horizontal", "style": "IPY_MODEL_d9792cd6d5034352a3a9f2122bb5d9c0", "value": 54 } }, "08ab7aae4ac341909798caf190c84ada": { "model_module": "@jupyter-widgets/controls", "model_name": "HTMLModel", "model_module_version": "1.5.0", "state": { "_dom_classes": [], "_model_module": "@jupyter-widgets/controls", "_model_module_version": "1.5.0", "_model_name": "HTMLModel", "_view_count": null, "_view_module": "@jupyter-widgets/controls", "_view_module_version": "1.5.0", "_view_name": "HTMLView", "description": "", "description_tooltip": null, "layout": "IPY_MODEL_8a9c974907c74fe29b6a323df7df0d4d", "placeholder": "​", "style": "IPY_MODEL_40ae1be859d74847b4f0944c4027e1cf", "value": " 54/64 [07:50<01:35, 9.52s/it]" } }, "9decfef2a41f42f0a3b77dfaa3a02bac": { "model_module": "@jupyter-widgets/base", "model_name": "LayoutModel", "model_module_version": "1.2.0", "state": { "_model_module": "@jupyter-widgets/base", "_model_module_version": "1.2.0", "_model_name": "LayoutModel", "_view_count": null, "_view_module": "@jupyter-widgets/base", "_view_module_version": "1.2.0", "_view_name": "LayoutView", "align_content": null, "align_items": null, "align_self": null, "border": null, "bottom": null, "display": null, "flex": null, "flex_flow": null, "grid_area": null, "grid_auto_columns": null, "grid_auto_flow": null, "grid_auto_rows": null, "grid_column": null, "grid_gap": null, "grid_row": null, "grid_template_areas": null, "grid_template_columns": null, "grid_template_rows": null, "height": null, "justify_content": null, "justify_items": null, "left": null, "margin": null, "max_height": null, "max_width": null, "min_height": null, "min_width": null, "object_fit": null, "object_position": null, "order": null, "overflow": null, "overflow_x": null, "overflow_y": null, "padding": null, "right": null, "top": null, "visibility": null, "width": null } }, "a0f24920a480438381da74562a7f7df1": { "model_module": "@jupyter-widgets/base", "model_name": "LayoutModel", "model_module_version": "1.2.0", "state": { "_model_module": "@jupyter-widgets/base", "_model_module_version": "1.2.0", "_model_name": "LayoutModel", "_view_count": null, "_view_module": "@jupyter-widgets/base", "_view_module_version": "1.2.0", "_view_name": "LayoutView", "align_content": null, "align_items": null, "align_self": null, "border": null, "bottom": null, "display": null, "flex": null, "flex_flow": null, "grid_area": null, "grid_auto_columns": null, "grid_auto_flow": null, "grid_auto_rows": null, "grid_column": null, "grid_gap": null, "grid_row": null, "grid_template_areas": null, "grid_template_columns": null, "grid_template_rows": null, "height": null, "justify_content": null, "justify_items": null, "left": null, "margin": null, "max_height": null, "max_width": null, "min_height": null, "min_width": null, "object_fit": null, "object_position": null, "order": null, "overflow": null, "overflow_x": null, "overflow_y": null, "padding": null, "right": null, "top": null, "visibility": null, "width": null } }, "bc4723c3d801406b891f808c84e9e83b": { "model_module": "@jupyter-widgets/controls", "model_name": "DescriptionStyleModel", "model_module_version": "1.5.0", "state": { "_model_module": "@jupyter-widgets/controls", "_model_module_version": "1.5.0", "_model_name": "DescriptionStyleModel", "_view_count": null, "_view_module": "@jupyter-widgets/base", "_view_module_version": "1.2.0", "_view_name": "StyleView", "description_width": "" } }, "c464d7549104481a90f75f3e5b219189": { "model_module": "@jupyter-widgets/base", "model_name": "LayoutModel", "model_module_version": "1.2.0", "state": { "_model_module": "@jupyter-widgets/base", "_model_module_version": "1.2.0", "_model_name": "LayoutModel", "_view_count": null, "_view_module": "@jupyter-widgets/base", "_view_module_version": "1.2.0", "_view_name": "LayoutView", "align_content": null, "align_items": null, "align_self": null, "border": null, "bottom": null, "display": null, "flex": null, "flex_flow": null, "grid_area": null, "grid_auto_columns": null, "grid_auto_flow": null, "grid_auto_rows": null, "grid_column": null, "grid_gap": null, "grid_row": null, "grid_template_areas": null, "grid_template_columns": null, "grid_template_rows": null, "height": null, "justify_content": null, "justify_items": null, "left": null, "margin": null, "max_height": null, "max_width": null, "min_height": null, "min_width": null, "object_fit": null, "object_position": null, "order": null, "overflow": null, "overflow_x": null, "overflow_y": null, "padding": null, "right": null, "top": null, "visibility": null, "width": null } }, "d9792cd6d5034352a3a9f2122bb5d9c0": { "model_module": "@jupyter-widgets/controls", "model_name": "ProgressStyleModel", "model_module_version": "1.5.0", "state": { "_model_module": "@jupyter-widgets/controls", "_model_module_version": "1.5.0", "_model_name": "ProgressStyleModel", "_view_count": null, "_view_module": "@jupyter-widgets/base", "_view_module_version": "1.2.0", "_view_name": "StyleView", "bar_color": null, "description_width": "" } }, "8a9c974907c74fe29b6a323df7df0d4d": { "model_module": "@jupyter-widgets/base", "model_name": "LayoutModel", "model_module_version": "1.2.0", "state": { "_model_module": "@jupyter-widgets/base", "_model_module_version": "1.2.0", "_model_name": "LayoutModel", "_view_count": null, "_view_module": "@jupyter-widgets/base", "_view_module_version": "1.2.0", "_view_name": "LayoutView", "align_content": null, "align_items": null, "align_self": null, "border": null, "bottom": null, "display": null, "flex": null, "flex_flow": null, "grid_area": null, "grid_auto_columns": null, "grid_auto_flow": null, "grid_auto_rows": null, "grid_column": null, "grid_gap": null, "grid_row": null, "grid_template_areas": null, "grid_template_columns": null, "grid_template_rows": null, "height": null, "justify_content": null, "justify_items": null, "left": null, "margin": null, "max_height": null, "max_width": null, "min_height": null, "min_width": null, "object_fit": null, "object_position": null, "order": null, "overflow": null, "overflow_x": null, "overflow_y": null, "padding": null, "right": null, "top": null, "visibility": null, "width": null } }, "40ae1be859d74847b4f0944c4027e1cf": { "model_module": "@jupyter-widgets/controls", "model_name": "DescriptionStyleModel", "model_module_version": "1.5.0", "state": { "_model_module": "@jupyter-widgets/controls", "_model_module_version": "1.5.0", "_model_name": "DescriptionStyleModel", "_view_count": null, "_view_module": "@jupyter-widgets/base", "_view_module_version": "1.2.0", "_view_name": "StyleView", "description_width": "" } } } } }, "nbformat": 4, "nbformat_minor": 5 }