{ "cells": [ { "cell_type": "markdown", "metadata": { "id": "hMBwJT0r38tj", "tags": [] }, "source": [ "# Lab 2: Korean-English Translation on SageMaker Training instances\n", "\n", "---" ] }, { "cell_type": "markdown", "metadata": { "id": "Amc52mb94Jzq" }, "source": [ "\n", "## Introduction\n", "---\n", "\n", "바로 이전 모듈에서 기존에 온프레미스에서 개발했던 환경과 동일한 환경으로 모델을 빌드하고 훈련했습니다. 하지만 아래와 같은 상황들에서도 기존 환경을 사용하는 것이 바람직할까요?\n", "\n", "- 온프레미스의 GPU는 총 1장으로 훈련 시간이 너무 오래 소요됨\n", "- 가용 서버 대수가 2대인데 10개의 딥러닝 모델을 동시에 훈련해야 함\n", "- 필요한 상황에만 GPU를 활용\n", "- 기타 등등\n", "\n", "Amazon SageMaker는 데이터 과학자들 및 머신 러닝 엔지니어들을 위한 완전 관리형 머신 러닝 서비스로 훈련 및 추론 수행 시 인프라 설정에 대한 추가 작업이 필요하지 않기에, 단일 GPU 기반의 딥러닝 훈련을 포함한 멀티 GPU 및 멀티 인스턴스 분산 훈련을 보다 쉽고 빠르게 수행할 수 있습니다. SageMaker는 다양한 유즈케이스들에 적합한 예제들을 지속적으로 업데이트하고 있으며, 한국어 세션 및 자료들도 제공되고 있습니다.\n", "\n", "### Notes\n", "\n", "이미 기본적인 Hugging Face 용법 및 자연어 처리에 익숙하신 분들은 앞 모듈을 생략하고 이 모듈부터 핸즈온을 시작하셔도 됩니다.\n", "이 노트북은 SageMaker 기본 API를 참조하므로, SageMaker Studio, SageMaker 노트북 인스턴스 또는 AWS CLI가 설정된 로컬 시스템에서 실행해야 합니다. SageMaker Studio 또는 SageMaker 노트북 인스턴스를 사용하는 경우 PyTorch 기반 커널을 선택하세요.\n", "훈련 job 수행 시 최소 `ml.g4dn.xlarge` 이상의 훈련 인스턴스가 필요하며, `ml.p3.8xlarge`나 `ml.p3.16xlarge` 인스턴스를 권장합니다. 만약 인스턴스 사용에 제한이 걸려 있다면 Request a service quota increase for SageMaker resources를 참조하여 인스턴스 제한을 해제해 주세요.\n", "\n", "### References\n", "- Hugging Face Tutorial: https://huggingface.co/docs/transformers/training" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "\n", "## 1. Setup Environments\n", "---\n", "\n", "### Import modules" ] }, { "cell_type": "code", "execution_count": 1, "metadata": {}, "outputs": [ { "name": "stdout", "output_type": "stream", "text": [ "sagemaker role arn: arn:aws:iam::143656149352:role/service-role/AmazonSageMaker-ExecutionRole-20220317T150353\n", "sagemaker bucket: sagemaker-us-east-1-143656149352\n", "sagemaker session region: us-east-1\n" ] } ], "source": [ "import boto3\n", "import sagemaker\n", "import sagemaker.huggingface\n", "\n", "sess = sagemaker.Session()\n", "# sagemaker session bucket -> used for uploading data, models and logs\n", "# sagemaker will automatically create this bucket if it not exists\n", "sagemaker_session_bucket=None\n", "if sagemaker_session_bucket is None and sess is not None:\n", " # set to default bucket if a bucket name is not given\n", " sagemaker_session_bucket = sess.default_bucket()\n", "\n", "role = sagemaker.get_execution_role()\n", "region = boto3.Session().region_name\n", "sess = sagemaker.Session(default_bucket=sagemaker_session_bucket)\n", "\n", "print(f\"sagemaker role arn: {role}\")\n", "print(f\"sagemaker bucket: {sess.default_bucket()}\")\n", "print(f\"sagemaker session region: {sess.boto_region_name}\")" ] }, { "cell_type": "code", "execution_count": 2, "metadata": {}, "outputs": [], "source": [ "import os\n", "import sys\n", "import json\n", "import logging\n", "import argparse\n", "import torch\n", "from torch import nn\n", "import numpy as np\n", "import pandas as pd\n", "from tqdm import tqdm\n", "from IPython.display import display, HTML\n", "\n", "from transformers import (\n", " AutoTokenizer, AutoModelForSeq2SeqLM, DataCollatorForSeq2Seq,\n", " Trainer, TrainingArguments, set_seed\n", ")\n", "from transformers import Seq2SeqTrainingArguments, Seq2SeqTrainer\n", "\n", "from transformers.trainer_utils import get_last_checkpoint\n", "from datasets import load_dataset, load_metric, ClassLabel, Sequence\n", "\n", "logging.basicConfig(\n", " level=logging.INFO, \n", " format='[{%(filename)s:%(lineno)d} %(levelname)s - %(message)s',\n", " handlers=[\n", " logging.StreamHandler(sys.stdout)\n", " ]\n", ")\n", "logger = logging.getLogger(__name__)" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "### Load Feature set" ] }, { "cell_type": "code", "execution_count": 3, "metadata": {}, "outputs": [], "source": [ "train_dir = 'seq2seq_translate_train'\n", "valid_dir = 'seq2seq_translate_valid'" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "### Uploading data to Amazon S3 Bucket\n", "\n", "SageMaker 훈련을 위해 데이터셋을 S3로 업로드합니다." ] }, { "cell_type": "code", "execution_count": 4, "metadata": {}, "outputs": [], "source": [ "bucket = sess.default_bucket()\n", "\n", "# s3 key prefix for the data\n", "s3_prefix = 'samples/datasets/seq2seq-translate'\n", "\n", "# save train_dataset to s3\n", "train_input_path = f's3://{bucket}/{s3_prefix}/train'\n", "valid_input_path = f's3://{bucket}/{s3_prefix}/valid'" ] }, { "cell_type": "code", "execution_count": 5, "metadata": {}, "outputs": [ { "name": "stdout", "output_type": "stream", "text": [ "CPU times: user 27.8 ms, sys: 37.1 ms, total: 64.9 ms\n", "Wall time: 1.49 s\n" ] } ], "source": [ "%%time\n", "!aws s3 cp {train_dir} {train_input_path} --recursive --quiet\n", "!aws s3 cp {valid_dir} {valid_input_path} --recursive --quiet" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "
\n", "\n", "## 2. Training with Native Hugging Face (PyTorch Framework)\n", "\n", "---\n", "\n", "### Overview and Training Script\n", "\n", "SageMaker에 대한 대표적인 오해가 여전히 많은 분들이 SageMaker 훈련을 위해 소스 코드를 전면적으로 수정해야 한다고 생각합니다. 하지만, 실제로는 별도의 소스 코드 수정 없이 기존 여러분이 사용했던 파이썬 스크립트에 SageMaker 훈련에 필요한 SageMaker 전용 환경 변수들만 추가하면 됩니다. \n", "\n", "SageMaker 훈련은 훈련 작업을 호출할 때, 1) 훈련 EC2 인스턴스 프로비저닝 - 2) 컨테이너 구동을 위한 도커 이미지 및 훈련 데이터 다운로드 - 3) 컨테이너 구동 - 4) 컨테이너 환경에서 훈련 수행 - 5) 컨테이너 환경에서 S3의 특정 버킷에 저장 - 6) 훈련 인스턴스 종료로 구성됩니다. 따라서, 훈련 수행 로직은 아래 예시와 같이 기존 개발 환경과 동일합니다.\n", "\n", "```python\n", "/opt/conda/bin/python train.py --epochs 5 --train_batch_size 32 ...\n", "```\n", "\n", "이 과정에서 컨테이너 환경에 필요한 환경 변수(예: 모델 경로, 훈련 데이터 경로) 들은 사전에 지정되어 있으며, 이 환경 변수들이 설정되어 있어야 훈련에 필요한 파일들의 경로를 인식할 수 있습니다. 대표적인 환경 변수들에 대한 자세한 내용은 https://github.com/aws/sagemaker-containers#important-environment-variables 을 참조하세요." ] }, { "cell_type": "code", "execution_count": 6, "metadata": {}, "outputs": [ { "name": "stdout", "output_type": "stream", "text": [ "[{3625818344.py:8} INFO - learning_rate: 3e-05\n" ] } ], "source": [ "from sagemaker.huggingface import HuggingFace\n", "import time\n", "instance_type = 'ml.g5.12xlarge'\n", "num_gpus = 4\n", "instance_count = 1\n", "batch_size = 32\n", "learning_rate = 3e-5\n", "logger.info(f'learning_rate: {learning_rate}')\n", "\n", "# hyperparameters, which are passed into the training job\n", "hyperparameters = {\n", " 'n_gpus': num_gpus, # number of GPUs per instance\n", " 'epochs': 1, # number of training epochs\n", " 'seed': 42, # random seed\n", " 'debug': True, # debug mode\n", " 'fp16': True, # use FP16\n", " 'disable_tqdm': True, # disable tqdm?\n", " 'train_batch_size': batch_size, # batch size for training\n", " 'eval_batch_size': batch_size, # batch size for evaluation\n", " 'learning_rate': learning_rate, # learning rate used during training\n", "}" ] }, { "cell_type": "code", "execution_count": 7, "metadata": {}, "outputs": [ { "name": "stdout", "output_type": "stream", "text": [ "[{2254912297.py:24} INFO - training job name: kornlp-translate-training-2022-08-01-14-27-50\n" ] } ], "source": [ "# define Training Job Name \n", "job_name = f'kornlp-translate-training-{time.strftime(\"%Y-%m-%d-%H-%M-%S\", time.localtime())}'\n", "chkpt_s3_path = f's3://{bucket}/{s3_prefix}/native/checkpoints'\n", "\n", "# create the Estimator\n", "sm_estimator = HuggingFace(\n", " entry_point = 'train.py', # fine-tuning script used in training jon\n", " source_dir = './scripts', # directory where fine-tuning script is stored\n", " #instance_type = 'local_gpu',\n", " instance_type = instance_type, # instances type used for the training job\n", " instance_count = instance_count, # the number of instances used for training\n", " base_job_name = job_name, # the name of the training job\n", " role = role, # IAM role used in training job to access AWS ressources, e.g. S3\n", " transformers_version = '4.17.0', # the transformers version used in the training job\n", " pytorch_version = '1.10.2', # the pytorch_version version used in the training job\n", " py_version = 'py38', # the python version used in the training job\n", " hyperparameters = hyperparameters, # the hyperparameter used for running the training job\n", " disable_profiler = True,\n", " debugger_hook_config = False, \n", " #checkpoint_s3_uri = chkpt_s3_path,\n", " #checkpoint_local_path ='/opt/ml/checkpoints', \n", ")\n", "\n", "logger.info(f'training job name: {job_name}')" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "`fit()` 메소드를 호출하여 훈련 job을 시작합니다. `fit()` 메소드의 인자값 중 `wait=True`로 설정할 경우에는 동기(synchronous) 방식으로 동직하게 되며, `wait=False`일 경우에는 비동기(aynchronous) 방식으로 동작하여 여러 개의 훈련 job을 동시에 실행할 수 있습니다." ] }, { "cell_type": "code", "execution_count": 8, "metadata": {}, "outputs": [ { "name": "stdout", "output_type": "stream", "text": [ "[{session.py:590} INFO - Creating training-job with name: kornlp-translate-training-2022-08-01-14-2022-08-01-14-27-51-097\n" ] } ], "source": [ "# define a data input dictonary with our uploaded s3 uris\n", "data = {\n", " 'train': train_input_path,\n", " 'valid': valid_input_path,\n", "}\n", "\n", "# starting the train job with our uploaded datasets as input\n", "sm_estimator.fit(data, wait=False)\n", "train_job_name = sm_estimator.latest_training_job.job_name" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "### View Training Job\n", "SageMaker 콘솔 창에서 훈련 내역을 직접 확인할 수도 있지만, 아래 코드 셀에서 생성되는 링크를 클릭하면 더 편리하게 훈련 내역을 확인할 수 있습니다." ] }, { "cell_type": "code", "execution_count": 9, "metadata": {}, "outputs": [ { "data": { "text/html": [ " [Hugging Face Training - Native] Review Training Job" ], "text/plain": [ "" ] }, "metadata": {}, "output_type": "display_data" }, { "data": { "text/html": [ " [Hugging Face Training - Native] Review CloudWatch Logs" ], "text/plain": [ "" ] }, "metadata": {}, "output_type": "display_data" } ], "source": [ "from IPython.core.display import display, HTML\n", "\n", "def make_console_link(region, train_job_name, train_task='[Training]'):\n", " train_job_link = f' {train_task} Review Training Job' \n", " cloudwatch_link = f' {train_task} Review CloudWatch Logs'\n", " return train_job_link, cloudwatch_link \n", " \n", "train_job_link, cloudwatch_link = make_console_link(region, train_job_name, '[Hugging Face Training - Native]')\n", "\n", "display(HTML(train_job_link))\n", "display(HTML(cloudwatch_link))" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "### Wait for the training jobs to complete\n", "훈련이 완료될 때까지 기다립니다. `estimator.fit(...)`에서 `wait=False`로 설정한 경우, 아래 코드 셀의 주석을 해제 후 실행하여 동기 방식으로 변경할 수도 있습니다. 훈련 완료까지는 약 15-20분의 시간이 소요됩니다." ] }, { "cell_type": "code", "execution_count": null, "metadata": {}, "outputs": [], "source": [ "#sess.logs_for_job(job_name=train_job_name, wait=True)" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "### Copy model artifacts from S3 to local path\n", "\n", "훈련된 모델 파라메터는 `model.tar.gz`로 압축되어 S3에 저장됩니다. 만약 SageMaker 상에서 훈련한 모델을 곧바로 배포한다면, 아래 코드 셀을 실행할 필요는 없지만, 로컬/개발 환경에서 훈련된 모델을 간단히 테스트하거나 다른 환경에서 모델을 서빙할 때는 S3에 저장된 모델을 다운로드하셔야 합니다." ] }, { "cell_type": "code", "execution_count": 10, "metadata": {}, "outputs": [], "source": [ "local_model_dir = './model'\n", "!rm -rf {local_model_dir}\n", "s3_model_path = sm_estimator.model_data\n", "os.makedirs(local_model_dir, exist_ok=True)" ] }, { "cell_type": "code", "execution_count": 11, "metadata": {}, "outputs": [ { "name": "stdout", "output_type": "stream", "text": [ "download: s3://sagemaker-us-east-1-143656149352/kornlp-translate-training-2022-08-01-14-2022-08-01-14-27-51-097/output/model.tar.gz to model/model.tar.gz\n", "pytorch_model.bin\n", "tokenizer_config.json\n", "target.spm\n", "training_args.bin\n", "config.json\n", "special_tokens_map.json\n", "vocab.json\n", "source.spm\n" ] } ], "source": [ "%%bash -s \"$local_model_dir\" \"$s3_model_path\"\n", "aws s3 cp $2 $1\n", "cd $1\n", "tar -xzvf model.tar.gz" ] }, { "cell_type": "code", "execution_count": 12, "metadata": {}, "outputs": [ { "name": "stdout", "output_type": "stream", "text": [ "Stored 's3_model_path' (str)\n", "Stored 'local_model_dir' (str)\n", "Stored 'train_dir' (str)\n" ] } ], "source": [ "%store s3_model_path local_model_dir train_dir " ] } ], "metadata": { "accelerator": "TPU", "colab": { "authorship_tag": "ABX9TyPT/32fR6YbrNgmG6aLi8U7", "include_colab_link": true, "machine_shape": "hm", "name": "5_(BERT_실습)한국어 개체명 인식.ipynb", "provenance": [] }, "kernelspec": { "display_name": "conda_pytorch_p38", "language": "python", "name": "conda_pytorch_p38" }, "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.8.12" }, "widgets": { "application/vnd.jupyter.widget-state+json": { "1ac7cea5aaba45af9eddeaaee02e1e5a": { "model_module": "@jupyter-widgets/base", "model_name": "LayoutModel", "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 } }, "2ef88e8c35374ca69203a64d209745ea": { "model_module": "@jupyter-widgets/base", "model_name": "LayoutModel", "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 } }, "32c340873ce247e88df66c73309eecdc": { "model_module": "@jupyter-widgets/controls", "model_name": "DescriptionStyleModel", "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": "" } }, "4a4ff12bb4604faf8c1cd79156713854": { "model_module": "@jupyter-widgets/controls", "model_name": "ProgressStyleModel", "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": "initial" } }, "51eafe68808a4ffbac05605381c2d5a3": { "model_module": "@jupyter-widgets/base", "model_name": "LayoutModel", "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 } }, "598f160635264f138769ae94a127455c": { "model_module": "@jupyter-widgets/controls", "model_name": "FloatProgressModel", "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": "Downloading: 100%", "description_tooltip": null, "layout": "IPY_MODEL_1ac7cea5aaba45af9eddeaaee02e1e5a", "max": 1961828, "min": 0, "orientation": "horizontal", "style": "IPY_MODEL_b61fb58de9be4c84b7767bf69e32c5d9", "value": 1961828 } }, "5b0843766d3f4ac785c7dba85254d605": { "model_module": "@jupyter-widgets/controls", "model_name": "HBoxModel", "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_ca07bf481be7473ab1b22babaa76c3da", "IPY_MODEL_ab60a81459a84ae19fa922aa4ce27e8a" ], "layout": "IPY_MODEL_6356e0609f9f49d5996ef7f4f77fbd2d" } }, "6356e0609f9f49d5996ef7f4f77fbd2d": { "model_module": "@jupyter-widgets/base", "model_name": "LayoutModel", "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 } }, "693887ccba30416586e2085b7e36118b": { "model_module": "@jupyter-widgets/controls", "model_name": "HTMLModel", "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_9169c98d7ee5423ba5b6eb3c4dbbeda7", "placeholder": "​", "style": "IPY_MODEL_cc353722b52045efb9009ef79c7d56b7", "value": " 1.96M/1.96M [00:00<00:00, 6.43MB/s]" } }, "6cb6badcbbd34359be9dad2c8af93098": { "model_module": "@jupyter-widgets/controls", "model_name": "DescriptionStyleModel", "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": "" } }, "88f28f34de9e41cc948c7aebb4035589": { "model_module": "@jupyter-widgets/base", "model_name": "LayoutModel", "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 } }, "8d879e2bbea04536aaa1ee5d356bb7c3": { "model_module": "@jupyter-widgets/controls", "model_name": "HTMLModel", "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_2ef88e8c35374ca69203a64d209745ea", "placeholder": "​", "style": "IPY_MODEL_32c340873ce247e88df66c73309eecdc", "value": " 29.0/29.0 [00:00<00:00, 50.2B/s]" } }, "9169c98d7ee5423ba5b6eb3c4dbbeda7": { "model_module": "@jupyter-widgets/base", "model_name": "LayoutModel", "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 } }, "93234e1bd6444d819b130d83402d2d7b": { "model_module": "@jupyter-widgets/controls", "model_name": "HBoxModel", "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_e6e0a2274e7f420f91dc97a143315da0", "IPY_MODEL_8d879e2bbea04536aaa1ee5d356bb7c3" ], "layout": "IPY_MODEL_ad295e710380441588473f810a9210d7" } }, "a0dbf235f20c497186d319b5b1558dd9": { "model_module": "@jupyter-widgets/controls", "model_name": "ProgressStyleModel", "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": "initial" } }, "ab60a81459a84ae19fa922aa4ce27e8a": { "model_module": "@jupyter-widgets/controls", "model_name": "HTMLModel", "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_51eafe68808a4ffbac05605381c2d5a3", "placeholder": "​", "style": "IPY_MODEL_6cb6badcbbd34359be9dad2c8af93098", "value": " 996k/996k [00:00<00:00, 1.67MB/s]" } }, "ad295e710380441588473f810a9210d7": { "model_module": "@jupyter-widgets/base", "model_name": "LayoutModel", "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 } }, "b61fb58de9be4c84b7767bf69e32c5d9": { "model_module": "@jupyter-widgets/controls", "model_name": "ProgressStyleModel", "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": "initial" } }, "ca07bf481be7473ab1b22babaa76c3da": { "model_module": "@jupyter-widgets/controls", "model_name": "FloatProgressModel", "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": "Downloading: 100%", "description_tooltip": null, "layout": "IPY_MODEL_88f28f34de9e41cc948c7aebb4035589", "max": 995526, "min": 0, "orientation": "horizontal", "style": "IPY_MODEL_4a4ff12bb4604faf8c1cd79156713854", "value": 995526 } }, "cc353722b52045efb9009ef79c7d56b7": { "model_module": "@jupyter-widgets/controls", "model_name": "DescriptionStyleModel", "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": "" } }, "e4dcb08aab3748b18a10d0f5daaf3554": { "model_module": "@jupyter-widgets/controls", "model_name": "HBoxModel", "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_598f160635264f138769ae94a127455c", "IPY_MODEL_693887ccba30416586e2085b7e36118b" ], "layout": "IPY_MODEL_f1ed2fc28a3e499fa784d5aa1777a77b" } }, "e6e0a2274e7f420f91dc97a143315da0": { "model_module": "@jupyter-widgets/controls", "model_name": "FloatProgressModel", "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": "Downloading: 100%", "description_tooltip": null, "layout": "IPY_MODEL_ed834b7f997141479ab90216655e230a", "max": 29, "min": 0, "orientation": "horizontal", "style": "IPY_MODEL_a0dbf235f20c497186d319b5b1558dd9", "value": 29 } }, "ed834b7f997141479ab90216655e230a": { "model_module": "@jupyter-widgets/base", "model_name": "LayoutModel", "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 } }, "f1ed2fc28a3e499fa784d5aa1777a77b": { "model_module": "@jupyter-widgets/base", "model_name": "LayoutModel", "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 } } } } }, "nbformat": 4, "nbformat_minor": 4 }