코랩 기초 및 파이썬 기초 수정
This commit is contained in:
1 parent
a1cb6fcdf9
commit
ba88ef63f1
23 files changed
+4707
-77
No files matched your search
Executable
+1
@@ -0,0 +1 @@
|
|||||||
|
{"cells":[{"cell_type":"markdown","metadata":{"id":"giIKZavhbhOn"},"source":["# Behind the pipeline (PyTorch)"]},{"cell_type":"markdown","metadata":{"id":"BOHmqSSmbhOs"},"source":["Install the Transformers, Datasets, and Evaluate libraries to run this notebook."]},{"cell_type":"code","execution_count":2,"metadata":{"id":"K8ZhhL0kbhOt","colab":{"base_uri":"https://localhost:8080/"},"collapsed":true,"executionInfo":{"status":"ok","timestamp":1779168824837,"user_tz":-540,"elapsed":4111,"user":{"displayName":"강사박진경","userId":"16101567623608115497"}},"outputId":"bcc1bd3a-f723-4d90-cec5-ab1e29510a5c"},"outputs":[{"output_type":"stream","name":"stdout","text":["Requirement already satisfied: datasets in /usr/local/lib/python3.12/dist-packages (4.0.0)\n","Requirement already satisfied: evaluate in /usr/local/lib/python3.12/dist-packages (0.4.6)\n","Requirement already satisfied: transformers==4.41.2 in /usr/local/lib/python3.12/dist-packages (from transformers[sentencepiece]==4.41.2) (4.41.2)\n","Requirement already satisfied: filelock in /usr/local/lib/python3.12/dist-packages (from transformers==4.41.2->transformers[sentencepiece]==4.41.2) (3.29.0)\n","Requirement already satisfied: huggingface-hub<1.0,>=0.23.0 in /usr/local/lib/python3.12/dist-packages (from transformers==4.41.2->transformers[sentencepiece]==4.41.2) (0.36.2)\n","Requirement already satisfied: numpy>=1.17 in /usr/local/lib/python3.12/dist-packages (from transformers==4.41.2->transformers[sentencepiece]==4.41.2) (2.0.2)\n","Requirement already satisfied: packaging>=20.0 in /usr/local/lib/python3.12/dist-packages (from transformers==4.41.2->transformers[sentencepiece]==4.41.2) (26.1)\n","Requirement already satisfied: pyyaml>=5.1 in /usr/local/lib/python3.12/dist-packages (from transformers==4.41.2->transformers[sentencepiece]==4.41.2) (6.0.3)\n","Requirement already satisfied: regex!=2019.12.17 in /usr/local/lib/python3.12/dist-packages (from transformers==4.41.2->transformers[sentencepiece]==4.41.2) (2025.11.3)\n","Requirement already satisfied: requests in /usr/local/lib/python3.12/dist-packages (from transformers==4.41.2->transformers[sentencepiece]==4.41.2) (2.32.4)\n","Requirement already satisfied: tokenizers<0.20,>=0.19 in /usr/local/lib/python3.12/dist-packages (from transformers==4.41.2->transformers[sentencepiece]==4.41.2) (0.19.1)\n","Requirement already satisfied: safetensors>=0.4.1 in /usr/local/lib/python3.12/dist-packages (from transformers==4.41.2->transformers[sentencepiece]==4.41.2) (0.7.0)\n","Requirement already satisfied: tqdm>=4.27 in /usr/local/lib/python3.12/dist-packages (from transformers==4.41.2->transformers[sentencepiece]==4.41.2) (4.67.3)\n","Requirement already satisfied: sentencepiece!=0.1.92,>=0.1.91 in /usr/local/lib/python3.12/dist-packages (from transformers[sentencepiece]==4.41.2) (0.2.1)\n","Requirement already satisfied: protobuf in /usr/local/lib/python3.12/dist-packages (from transformers[sentencepiece]==4.41.2) (5.29.6)\n","Requirement already satisfied: pyarrow>=15.0.0 in /usr/local/lib/python3.12/dist-packages (from datasets) (18.1.0)\n","Requirement already satisfied: dill<0.3.9,>=0.3.0 in /usr/local/lib/python3.12/dist-packages (from datasets) (0.3.8)\n","Requirement already satisfied: pandas in /usr/local/lib/python3.12/dist-packages (from datasets) (2.2.2)\n","Requirement already satisfied: xxhash in /usr/local/lib/python3.12/dist-packages (from datasets) (3.6.0)\n","Requirement already satisfied: multiprocess<0.70.17 in /usr/local/lib/python3.12/dist-packages (from datasets) (0.70.16)\n","Requirement already satisfied: fsspec<=2025.3.0,>=2023.1.0 in /usr/local/lib/python3.12/dist-packages (from fsspec[http]<=2025.3.0,>=2023.1.0->datasets) (2025.3.0)\n","Requirement already satisfied: aiohttp!=4.0.0a0,!=4.0.0a1 in /usr/local/lib/python3.12/dist-packages (from fsspec[http]<=2025.3.0,>=2023.1.0->datasets) (3.13.5)\n","Requirement already satisfied: hf-xet<2.0.0,>=1.1.3 in /usr/local/lib/python3.12/dist-packages (from huggingface-hub<1.0,>=0.23.0->transformers==4.41.2->transformers[sentencepiece]==4.41.2) (1.4.3)\n","Requirement already satisfied: typing-extensions>=3.7.4.3 in /usr/local/lib/python3.12/dist-packages (from huggingface-hub<1.0,>=0.23.0->transformers==4.41.2->transformers[sentencepiece]==4.41.2) (4.15.0)\n","Requirement already satisfied: charset_normalizer<4,>=2 in /usr/local/lib/python3.12/dist-packages (from requests->transformers==4.41.2->transformers[sentencepiece]==4.41.2) (3.4.7)\n","Requirement already satisfied: idna<4,>=2.5 in /usr/local/lib/python3.12/dist-packages (from requests->transformers==4.41.2->transformers[sentencepiece]==4.41.2) (3.13)\n","Requirement already satisfied: urllib3<3,>=1.21.1 in /usr/local/lib/python3.12/dist-packages (from requests->transformers==4.41.2->transformers[sentencepiece]==4.41.2) (2.5.0)\n","Requirement already satisfied: certifi>=2017.4.17 in /usr/local/lib/python3.12/dist-packages (from requests->transformers==4.41.2->transformers[Line truncated
|
||||||
@@ -0,0 +1 @@
|
|||||||
|
{"cells":[{"cell_type":"markdown","metadata":{"id":"sl90BFcgb3Gd"},"source":["# Fine-tuning a model with the Trainer API"]},{"cell_type":"markdown","metadata":{"id":"pZ67By2Rb3Ge"},"source":["Install the Transformers, Datasets, and Evaluate libraries to run this notebook."]},{"cell_type":"code","execution_count":1,"metadata":{"id":"Lpjg3fQhb3Gf","colab":{"base_uri":"https://localhost:8080/"},"collapsed":true,"executionInfo":{"status":"ok","timestamp":1779238411789,"user_tz":-540,"elapsed":16582,"user":{"displayName":"강사박진경","userId":"16101567623608115497"}},"outputId":"ffe976d5-ce10-45b4-9164-469af0d2da54"},"outputs":[{"output_type":"stream","name":"stdout","text":["Requirement already satisfied: datasets in /usr/local/lib/python3.12/dist-packages (4.0.0)\n","Collecting evaluate\n"," Downloading evaluate-0.4.6-py3-none-any.whl.metadata (9.5 kB)\n","Requirement already satisfied: transformers[sentencepiece] in /usr/local/lib/python3.12/dist-packages (5.0.0)\n","Requirement already satisfied: filelock in /usr/local/lib/python3.12/dist-packages (from datasets) (3.29.0)\n","Requirement already satisfied: numpy>=1.17 in /usr/local/lib/python3.12/dist-packages (from datasets) (2.0.2)\n","Requirement already satisfied: pyarrow>=15.0.0 in /usr/local/lib/python3.12/dist-packages (from datasets) (18.1.0)\n","Requirement already satisfied: dill<0.3.9,>=0.3.0 in /usr/local/lib/python3.12/dist-packages (from datasets) (0.3.8)\n","Requirement already satisfied: pandas in /usr/local/lib/python3.12/dist-packages (from datasets) (2.2.2)\n","Requirement already satisfied: requests>=2.32.2 in /usr/local/lib/python3.12/dist-packages (from datasets) (2.32.4)\n","Requirement already satisfied: tqdm>=4.66.3 in /usr/local/lib/python3.12/dist-packages (from datasets) (4.67.3)\n","Requirement already satisfied: xxhash in /usr/local/lib/python3.12/dist-packages (from datasets) (3.6.0)\n","Requirement already satisfied: multiprocess<0.70.17 in /usr/local/lib/python3.12/dist-packages (from datasets) (0.70.16)\n","Requirement already satisfied: fsspec<=2025.3.0,>=2023.1.0 in /usr/local/lib/python3.12/dist-packages (from fsspec[http]<=2025.3.0,>=2023.1.0->datasets) (2025.3.0)\n","Requirement already satisfied: huggingface-hub>=0.24.0 in /usr/local/lib/python3.12/dist-packages (from datasets) (1.11.0)\n","Requirement already satisfied: packaging in /usr/local/lib/python3.12/dist-packages (from datasets) (26.1)\n","Requirement already satisfied: pyyaml>=5.1 in /usr/local/lib/python3.12/dist-packages (from datasets) (6.0.3)\n","Requirement already satisfied: regex!=2019.12.17 in /usr/local/lib/python3.12/dist-packages (from transformers[sentencepiece]) (2025.11.3)\n","Requirement already satisfied: tokenizers<=0.23.0,>=0.22.0 in /usr/local/lib/python3.12/dist-packages (from transformers[sentencepiece]) (0.22.2)\n","Requirement already satisfied: typer-slim in /usr/local/lib/python3.12/dist-packages (from transformers[sentencepiece]) (0.24.0)\n","Requirement already satisfied: safetensors>=0.4.3 in /usr/local/lib/python3.12/dist-packages (from transformers[sentencepiece]) (0.7.0)\n","Requirement already satisfied: sentencepiece!=0.1.92,>=0.1.91 in /usr/local/lib/python3.12/dist-packages (from transformers[sentencepiece]) (0.2.1)\n","Requirement already satisfied: protobuf in /usr/local/lib/python3.12/dist-packages (from transformers[sentencepiece]) (5.29.6)\n","Requirement already satisfied: aiohttp!=4.0.0a0,!=4.0.0a1 in /usr/local/lib/python3.12/dist-packages (from fsspec[http]<=2025.3.0,>=2023.1.0->datasets) (3.13.5)\n","Requirement already satisfied: hf-xet<2.0.0,>=1.4.3 in /usr/local/lib/python3.12/dist-packages (from huggingface-hub>=0.24.0->datasets) (1.4.3)\n","Requirement already satisfied: httpx<1,>=0.23.0 in /usr/local/lib/python3.12/dist-packages (from huggingface-hub>=0.24.0->datasets) (0.28.1)\n","Requirement already satisfied: typer in /usr/local/lib/python3.12/dist-packages (from huggingface-hub>=0.24.0->datasets) (0.24.2)\n","Requirement already satisfied: typing-extensions>=4.1.0 in /usr/local/lib/python3.12/dist-packages (from huggingface-hub>=0.24.0->datasets) (4.15.0)\n","Requirement already satisfied: charset_normalizer<4,>=2 in /usr/local/lib/python3.12/dist-packages (from requests>=2.32.2->datasets) (3.4.7)\n","Requirement already satisfied: idna<4,>=2.5 in /usr/local/lib/python3.12/dist-packages (from requests>=2.32.2->datasets) (3.13)\n","Requirement already satisfied: urllib3<3,>=1.21.1 in /usr/local/lib/python3.12/dist-packages (from requests>=2.32.2->datasets) (2.5.0)\n","Requirement already satisfied: certifi>=2017.4.17 in /usr/local/lib/python3.12/dist-packages (from requests>=2.32.2->datasets) (2026.4.22)\n","Requirement already satisfied: python-dateutil>=2.8.2 in /usr/local/lib/python3.12/dist-packages (from pandas->datasets) (2.9.0.post0)\n","Requirement already satisfied: pytz>=2020.1 in /usr/local/lib/python3.12/dist-packages (from pandas->datasets) (2025.2)\n","Requirement already satisfied: tLine truncated
|
||||||
@@ -0,0 +1 @@
|
|||||||
|
{"cells":[{"cell_type":"markdown","metadata":{"id":"5QYneonVbwIj"},"source":["# Processing the data (PyTorch)"]},{"cell_type":"markdown","metadata":{"id":"2uvMdtwqbwIk"},"source":["Install the Transformers, Datasets, and Evaluate libraries to run this notebook."]},{"cell_type":"code","execution_count":43,"metadata":{"id":"kxvt4_2gbwIk","colab":{"base_uri":"https://localhost:8080/"},"executionInfo":{"status":"ok","timestamp":1779174438546,"user_tz":-540,"elapsed":5702,"user":{"displayName":"쿠니","userId":"18312388301484735023"}},"outputId":"b6c19692-1299-47e3-d79d-7dbfacb69786"},"outputs":[{"output_type":"stream","name":"stdout","text":["Requirement already satisfied: datasets in /usr/local/lib/python3.12/dist-packages (4.0.0)\n","Requirement already satisfied: evaluate in /usr/local/lib/python3.12/dist-packages (0.4.6)\n","Requirement already satisfied: transformers==4.41.2 in /usr/local/lib/python3.12/dist-packages (from transformers[sentencepiece]==4.41.2) (4.41.2)\n","Requirement already satisfied: filelock in /usr/local/lib/python3.12/dist-packages (from transformers==4.41.2->transformers[sentencepiece]==4.41.2) (3.29.0)\n","Requirement already satisfied: huggingface-hub<1.0,>=0.23.0 in /usr/local/lib/python3.12/dist-packages (from transformers==4.41.2->transformers[sentencepiece]==4.41.2) (0.36.2)\n","Requirement already satisfied: numpy>=1.17 in /usr/local/lib/python3.12/dist-packages (from transformers==4.41.2->transformers[sentencepiece]==4.41.2) (2.0.2)\n","Requirement already satisfied: packaging>=20.0 in /usr/local/lib/python3.12/dist-packages (from transformers==4.41.2->transformers[sentencepiece]==4.41.2) (26.1)\n","Requirement already satisfied: pyyaml>=5.1 in /usr/local/lib/python3.12/dist-packages (from transformers==4.41.2->transformers[sentencepiece]==4.41.2) (6.0.3)\n","Requirement already satisfied: regex!=2019.12.17 in /usr/local/lib/python3.12/dist-packages (from transformers==4.41.2->transformers[sentencepiece]==4.41.2) (2025.11.3)\n","Requirement already satisfied: requests in /usr/local/lib/python3.12/dist-packages (from transformers==4.41.2->transformers[sentencepiece]==4.41.2) (2.32.4)\n","Requirement already satisfied: tokenizers<0.20,>=0.19 in /usr/local/lib/python3.12/dist-packages (from transformers==4.41.2->transformers[sentencepiece]==4.41.2) (0.19.1)\n","Requirement already satisfied: safetensors>=0.4.1 in /usr/local/lib/python3.12/dist-packages (from transformers==4.41.2->transformers[sentencepiece]==4.41.2) (0.7.0)\n","Requirement already satisfied: tqdm>=4.27 in /usr/local/lib/python3.12/dist-packages (from transformers==4.41.2->transformers[sentencepiece]==4.41.2) (4.67.3)\n","Requirement already satisfied: sentencepiece!=0.1.92,>=0.1.91 in /usr/local/lib/python3.12/dist-packages (from transformers[sentencepiece]==4.41.2) (0.2.1)\n","Requirement already satisfied: protobuf in /usr/local/lib/python3.12/dist-packages (from transformers[sentencepiece]==4.41.2) (5.29.6)\n","Requirement already satisfied: pyarrow>=15.0.0 in /usr/local/lib/python3.12/dist-packages (from datasets) (18.1.0)\n","Requirement already satisfied: dill<0.3.9,>=0.3.0 in /usr/local/lib/python3.12/dist-packages (from datasets) (0.3.8)\n","Requirement already satisfied: pandas in /usr/local/lib/python3.12/dist-packages (from datasets) (2.2.2)\n","Requirement already satisfied: xxhash in /usr/local/lib/python3.12/dist-packages (from datasets) (3.6.0)\n","Requirement already satisfied: multiprocess<0.70.17 in /usr/local/lib/python3.12/dist-packages (from datasets) (0.70.16)\n","Requirement already satisfied: fsspec<=2025.3.0,>=2023.1.0 in /usr/local/lib/python3.12/dist-packages (from fsspec[http]<=2025.3.0,>=2023.1.0->datasets) (2025.3.0)\n","Requirement already satisfied: aiohttp!=4.0.0a0,!=4.0.0a1 in /usr/local/lib/python3.12/dist-packages (from fsspec[http]<=2025.3.0,>=2023.1.0->datasets) (3.13.5)\n","Requirement already satisfied: hf-xet<2.0.0,>=1.1.3 in /usr/local/lib/python3.12/dist-packages (from huggingface-hub<1.0,>=0.23.0->transformers==4.41.2->transformers[sentencepiece]==4.41.2) (1.4.3)\n","Requirement already satisfied: typing-extensions>=3.7.4.3 in /usr/local/lib/python3.12/dist-packages (from huggingface-hub<1.0,>=0.23.0->transformers==4.41.2->transformers[sentencepiece]==4.41.2) (4.15.0)\n","Requirement already satisfied: charset_normalizer<4,>=2 in /usr/local/lib/python3.12/dist-packages (from requests->transformers==4.41.2->transformers[sentencepiece]==4.41.2) (3.4.7)\n","Requirement already satisfied: idna<4,>=2.5 in /usr/local/lib/python3.12/dist-packages (from requests->transformers==4.41.2->transformers[sentencepiece]==4.41.2) (3.13)\n","Requirement already satisfied: urllib3<3,>=1.21.1 in /usr/local/lib/python3.12/dist-packages (from requests->transformers==4.41.2->transformers[sentencepiece]==4.41.2) (2.5.0)\n","Requirement already satisfied: certifi>=2017.4.17 in /usr/local/lib/python3.12/dist-packages (from requests->transformers==4.41.2->transformers[sentencepiece]==4.41.2) (Line truncated
|
||||||
@@ -0,0 +1 @@
|
|||||||
|
{"nbformat":4,"nbformat_minor":0,"metadata":{"colab":{"name":"Untitled","authorship_tag":"ABX9TyOw7VNSeqhRP+eOellpIRQg"},"kernelspec":{"name":"python3","display_name":"Python 3"},"language_info":{"name":"python"}},"cells":[{"cell_type":"code","execution_count":0,"metadata":{},"outputs":[],"source":[""]}]}
|
||||||
@@ -0,0 +1 @@
|
|||||||
|
{"nbformat":4,"nbformat_minor":0,"metadata":{"colab":{"provenance":[],"authorship_tag":"ABX9TyMa7ybUWuUj1+ud5HMXowhK"},"kernelspec":{"name":"python3","display_name":"Python 3"},"language_info":{"name":"python"}},"cells":[{"cell_type":"code","execution_count":1,"metadata":{"colab":{"base_uri":"https://localhost:8080/"},"id":"oKfpiooC3aQx","executionInfo":{"status":"ok","timestamp":1778557421821,"user_tz":-540,"elapsed":10,"user":{"displayName":"쿠니","userId":"18312388301484735023"}},"outputId":"778aef8d-2a09-4c71-b3f0-75c961c340e4"},"outputs":[{"output_type":"stream","name":"stdout","text":["Hello\n"]}],"source":["print(\"Hello\")"]}]}
|
||||||
@@ -0,0 +1 @@
|
|||||||
|
{"nbformat":4,"nbformat_minor":0,"metadata":{"colab":{"provenance":[],"authorship_tag":"ABX9TyOuI/HFRXnL2TxCZhFMJvEF"},"kernelspec":{"name":"python3","display_name":"Python 3"},"language_info":{"name":"python"}},"cells":[{"cell_type":"code","execution_count":null,"metadata":{"id":"fP-707OLlJF-"},"outputs":[],"source":["!pip install transformers[sentencepiece]==4.41.2 torch gradiO python-dotenv"]},{"cell_type":"code","source":["import gradio as gr\n","from transformers import pipeline\n","from PIL import Image\n","\n","captioner = pipeline(\"image-to-text\")\n","\n","def echo(message, history) :\n","\n"," # message {'text': 'text', 'files': []}\n"," # message {'text': '', 'files': ['/private/var/folders/_x/jfhn2s8d6t512jvv5lndzw2m0000gn/T/gradio/f299e1f235318c3c17f47efef61fabb3f52e14158f3c4e1a2f15b1cf0fb8329d/Gemini_Generated_Image_e9k4qje9k4qje9k4.png']}\n","\n"," # History[]\n"," # History[{'role': 'user', 'metadata': None, 'content': [{'text': 'text', 'type': 'text'}], 'options': None}, {'role': 'assistant', ']\n"," print(\"message\", message)\n"," print(\"history\", history)\n","\n"," # message에서 텍스트와 이미지 분리\n"," text = message[\"text\"]\n","\n"," if message.get(\"files\") :\n"," image = message[\"files\"][0]\n"," if image :\n"," # 이미지만\n"," result = captioner(image)\n"," return result[0]['generated_text']\n"," elif text :\n"," return text\n","\n","\n","\n","demo = gr.ChatInterface(\n"," fn=echo,\n"," multimodal=True,\n"," title=\"멀티 모달 AI 챗봇\",\n"," description=\"이미지를 업로드하면 이미지에 대한 설명을 생성하는 챗봇입니다. 테스트로 질문도 가능합니다.\",\n",")\n","demo.launch()"],"metadata":{"id":"XbKK4cPklO8T"},"execution_count":null,"outputs":[]},{"cell_type":"code","source":["import gradio as gr\n","from transformers import pipeline\n","from PIL import Image\n","\n","captioner = pipeline(\"image-to-text\")\n","\n","def chat(message, history) :\n","\n"," # message {'text': 'text', 'files': []}\n"," # message {'text': '', 'files': ['/private/var/folders/_x/jfhn2s8d6t512jvv5lndzw2m0000gn/T/gradio/f299e1f235318c3c17f47efef61fabb3f52e14158f3c4e1a2f15b1cf0fb8329d/Gemini_Generated_Image_e9k4qje9k4qje9k4.png']}\n","\n"," # History[]\n"," # History[{'role': 'user', 'metadata': None, 'content': [{'text': 'text', 'type': 'text'}], 'options': None}, {'role': 'assistant', ']\n"," print(\"message\", message)\n"," print(\"history\", history)\n","\n"," # message에서 텍스트와 이미지 분리\n"," text = message[\"text\"]\n","\n"," if message.get(\"files\") :\n"," image = message[\"files\"][0]\n"," if image :\n"," result = captioner(image)\n"," caption_result = result[0][\"generated_text\"]\n"," prompt = f\"\"\"\n"," 이미지 설명:\n"," {caption_result}\n","\n"," 사용자 질문:\n"," {text}\n"," \"\"\"\n"," return prompt\n"," elif text :\n"," return text\n","\n","\n","\n","demo = gr.ChatInterface(\n"," fn=chat,\n"," multimodal=True,\n"," title=\"멀티 모달 AI 챗봇\",\n"," description=\"이미지를 업로드하면 이미지에 대한 설명을 생성하는 챗봇입니다. 테스트로 질문도 가능합니다.\",\n",")\n","demo.launch()"],"metadata":{"colab":{"base_uri":"https://localhost:8080/","height":428},"id":"fuTWrcWQ9HyW","executionInfo":{"status":"error","timestamp":1779256780357,"user_tz":-540,"elapsed":44195,"user":{"displayName":"쿠니","userId":"18312388301484735023"}},"outputId":"9ff30f5c-eaff-4e1c-85bf-dde225532400"},"execution_count":1,"outputs":[{"output_type":"error","ename":"KeyError","evalue":"\"Unknown task image-to-text, available tasks are ['any-to-any', 'audio-classification', 'automatic-speech-recognition', 'depth-estimation', 'document-question-answering', 'feature-extraction', 'fill-mask', 'image-classification', 'image-feature-extraction', 'image-segmentation', 'image-text-to-text', 'image-to-image', 'keypoint-matching', 'mask-generation', 'ner', 'object-detection', 'question-answering', 'sentiment-analysis', 'table-question-answering', 'text-classification', 'text-generation', 'text-to-audio', 'text-to-speech', 'token-classification', 'video-classification', 'visual-question-answering', 'vqa', 'zero-shot-audio-classification', 'zero-shot-classification', 'zero-shot-image-classification', 'zero-shot-object-detection', 'translation_XX_to_YY']\"","traceback":["\u001b[0;31m---------------------------------------------------------------------------\u001b[0m","\u001b[0;31mKeyError\u001b[0m Traceback (most recent call last)","\u001b[0;32m/tmp/ipykernel_4438/1356788246.py\u001b[0m in \u001b[0;36m<cell line: 0>\u001b[0;34m()\u001b[0m\n\u001b[1;32m 3\u001b[0m \u001b[0;32mfrom\u001b[0m \u001b[0mPIL\u001b[0m \u0Line truncated
|
||||||
@@ -0,0 +1 @@
|
|||||||
|
{"nbformat":4,"nbformat_minor":0,"metadata":{"colab":{"provenance":[],"authorship_tag":"ABX9TyMy/MAvjpUXwHP1FrULJRFl"},"kernelspec":{"name":"python3","display_name":"Python 3"},"language_info":{"name":"python"}},"cells":[{"cell_type":"markdown","source":["### pandas\n","- 테이블형 테이터를 다룰 수 있는 다양한 기능을 가진 라이브러리\n","- 데이터 전처리를 하거나 다른 형식으로 데이터 저장시 사용 가능\n","- 데이터 분석 가능\n","- Series(1차원) - 컬럼\n","- DataFrame(2차원) - 표(주로사용)"],"metadata":{"id":"r70QKv8SCC45"}},{"cell_type":"code","execution_count":null,"metadata":{"colab":{"base_uri":"https://localhost:8080/","height":143},"collapsed":true,"id":"uEIahOOqBgMN","executionInfo":{"status":"ok","timestamp":1779326556741,"user_tz":-540,"elapsed":9,"user":{"displayName":"쿠니","userId":"18312388301484735023"}},"outputId":"bc151771-a60d-4e21-a6b5-c9df608c3e73"},"outputs":[{"output_type":"execute_result","data":{"text/plain":[" A\n","0 1\n","1 2\n","2 3"],"text/html":["\n"," <div id=\"df-aa3cb96c-111e-4320-bec7-db6926cb95c0\" class=\"colab-df-container\">\n"," <div>\n","<style scoped>\n"," .dataframe tbody tr th:only-of-type {\n"," vertical-align: middle;\n"," }\n","\n"," .dataframe tbody tr th {\n"," vertical-align: top;\n"," }\n","\n"," .dataframe thead th {\n"," text-align: right;\n"," }\n","</style>\n","<table border=\"1\" class=\"dataframe\">\n"," <thead>\n"," <tr style=\"text-align: right;\">\n"," <th></th>\n"," <th>A</th>\n"," </tr>\n"," </thead>\n"," <tbody>\n"," <tr>\n"," <th>0</th>\n"," <td>1</td>\n"," </tr>\n"," <tr>\n"," <th>1</th>\n"," <td>2</td>\n"," </tr>\n"," <tr>\n"," <th>2</th>\n"," <td>3</td>\n"," </tr>\n"," </tbody>\n","</table>\n","</div>\n"," <div class=\"colab-df-buttons\">\n","\n"," <div class=\"colab-df-container\">\n"," <button class=\"colab-df-convert\" onclick=\"convertToInteractive('df-aa3cb96c-111e-4320-bec7-db6926cb95c0')\"\n"," title=\"Convert this dataframe to an interactive table.\"\n"," style=\"display:none;\">\n","\n"," <svg xmlns=\"http://www.w3.org/2000/svg\" height=\"24px\" viewBox=\"0 -960 960 960\">\n"," <path d=\"M120-120v-720h720v720H120Zm60-500h600v-160H180v160Zm220 220h160v-160H400v160Zm0 220h160v-160H400v160ZM180-400h160v-160H180v160Zm440 0h160v-160H620v160ZM180-180h160v-160H180v160Zm440 0h160v-160H620v160Z\"/>\n"," </svg>\n"," </button>\n","\n"," <style>\n"," .colab-df-container {\n"," display:flex;\n"," gap: 12px;\n"," }\n","\n"," .colab-df-convert {\n"," background-color: #E8F0FE;\n"," border: none;\n"," border-radius: 50%;\n"," cursor: pointer;\n"," display: none;\n"," fill: #1967D2;\n"," height: 32px;\n"," padding: 0 0 0 0;\n"," width: 32px;\n"," }\n","\n"," .colab-df-convert:hover {\n"," background-color: #E2EBFA;\n"," box-shadow: 0px 1px 2px rgba(60, 64, 67, 0.3), 0px 1px 3px 1px rgba(60, 64, 67, 0.15);\n"," fill: #174EA6;\n"," }\n","\n"," .colab-df-buttons div {\n"," margin-bottom: 4px;\n"," }\n","\n"," [theme=dark] .colab-df-convert {\n"," background-color: #3B4455;\n"," fill: #D2E3FC;\n"," }\n","\n"," [theme=dark] .colab-df-convert:hover {\n"," background-color: #434B5C;\n"," box-shadow: 0px 1px 3px 1px rgba(0, 0, 0, 0.15);\n"," filter: drop-shadow(0px 1px 2px rgba(0, 0, 0, 0.3));\n"," fill: #FFFFFF;\n"," }\n"," </style>\n","\n"," <script>\n"," const buttonEl =\n"," document.querySelector('#df-aa3cb96c-111e-4320-bec7-db6926cb95c0 button.colab-df-convert');\n"," buttonEl.style.display =\n"," google.colab.kernel.accessAllowed ? 'block' : 'none';\n","\n"," async function convertToInteractive(key) {\n"," const element = document.querySelector('#df-aa3cb96c-111e-4320-bec7-db6926cb95c0');\n"," const dataTable =\n"," await google.colab.kernel.invokeFunction('convertToInteractive',\n"," [key], {});\n"," if (!dataTable) return;\n","\n"," const docLinkHtml = 'Like what you see? Visit the ' +\n"," '<a target=\"_blank\" href=https://colab.research.google.com/notebooks/data_table.ipynb>data table notebook</a>'\n"," + ' to learn more about interactive tables.';\n"," element.innerHTML = '';\n"," dataTable['output_type'] = 'display_data';\n"," await google.colab.output.renderOutput(dataTable, element);\n"," const docLink = document.createElement('div');\n"," docLink.innerHTML = docLinkHtml;\n"," element.appendChild(docLink);\n"," }\n"," </script>\n"," </div>\n","\n","\n"," <div id=\"id_2eaeae80-6bf5-4db6-a14b-375907ad0bbc\">\n"," <style>\n"," .colab-df-generate {\n"," background-color: #E8F0FE;\n"," Line truncated
|
||||||
Binary file not shown.
|
After Width: | Height: | Size: 5.3 KiB |
@@ -0,0 +1,4 @@
|
|||||||
|
name,age,job
|
||||||
|
John,25,student
|
||||||
|
Nate,30,teacher
|
||||||
|
Jenny,30,developer
|
||||||
|
Binary file not shown.
Binary file not shown.
|
After Width: | Height: | Size: 498 KiB |
Binary file not shown.
Executable
+1
@@ -0,0 +1 @@
|
|||||||
|
{"cells":[{"cell_type":"markdown","metadata":{"id":"uSL8FkrzEQH-"},"source":["# 트랜스포머로 무엇을 할 수 있나요?"]},{"cell_type":"markdown","metadata":{"id":"75RipA00EQH_"},"source":["Install the Transformers, Datasets, and Evaluate libraries to run this notebook."]},{"cell_type":"code","execution_count":null,"metadata":{"id":"bdIxnISxEQIA","colab":{"base_uri":"https://localhost:8080/"},"collapsed":true,"executionInfo":{"status":"ok","timestamp":1779242770789,"user_tz":-540,"elapsed":16770,"user":{"displayName":"강사박진경","userId":"16101567623608115497"}},"outputId":"28f2d47b-1acd-4d1d-813a-701fc8720c8a"},"outputs":[{"output_type":"stream","name":"stdout","text":["Requirement already satisfied: datasets in /usr/local/lib/python3.12/dist-packages (4.0.0)\n","Collecting evaluate\n"," Downloading evaluate-0.4.6-py3-none-any.whl.metadata (9.5 kB)\n","Collecting transformers==4.41.2 (from transformers[sentencepiece]==4.41.2)\n"," Downloading transformers-4.41.2-py3-none-any.whl.metadata (43 kB)\n","\u001b[2K \u001b[90m━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━\u001b[0m \u001b[32m43.8/43.8 kB\u001b[0m \u001b[31m3.9 MB/s\u001b[0m eta \u001b[36m0:00:00\u001b[0m\n","\u001b[?25hRequirement already satisfied: filelock in /usr/local/lib/python3.12/dist-packages (from transformers==4.41.2->transformers[sentencepiece]==4.41.2) (3.29.0)\n","Collecting huggingface-hub<1.0,>=0.23.0 (from transformers==4.41.2->transformers[sentencepiece]==4.41.2)\n"," Downloading huggingface_hub-0.36.2-py3-none-any.whl.metadata (15 kB)\n","Requirement already satisfied: numpy>=1.17 in /usr/local/lib/python3.12/dist-packages (from transformers==4.41.2->transformers[sentencepiece]==4.41.2) (2.0.2)\n","Requirement already satisfied: packaging>=20.0 in /usr/local/lib/python3.12/dist-packages (from transformers==4.41.2->transformers[sentencepiece]==4.41.2) (26.1)\n","Requirement already satisfied: pyyaml>=5.1 in /usr/local/lib/python3.12/dist-packages (from transformers==4.41.2->transformers[sentencepiece]==4.41.2) (6.0.3)\n","Requirement already satisfied: regex!=2019.12.17 in /usr/local/lib/python3.12/dist-packages (from transformers==4.41.2->transformers[sentencepiece]==4.41.2) (2025.11.3)\n","Requirement already satisfied: requests in /usr/local/lib/python3.12/dist-packages (from transformers==4.41.2->transformers[sentencepiece]==4.41.2) (2.32.4)\n","Collecting tokenizers<0.20,>=0.19 (from transformers==4.41.2->transformers[sentencepiece]==4.41.2)\n"," Downloading tokenizers-0.19.1-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.metadata (6.7 kB)\n","Requirement already satisfied: safetensors>=0.4.1 in /usr/local/lib/python3.12/dist-packages (from transformers==4.41.2->transformers[sentencepiece]==4.41.2) (0.7.0)\n","Requirement already satisfied: tqdm>=4.27 in /usr/local/lib/python3.12/dist-packages (from transformers==4.41.2->transformers[sentencepiece]==4.41.2) (4.67.3)\n","Requirement already satisfied: sentencepiece!=0.1.92,>=0.1.91 in /usr/local/lib/python3.12/dist-packages (from transformers[sentencepiece]==4.41.2) (0.2.1)\n","Requirement already satisfied: protobuf in /usr/local/lib/python3.12/dist-packages (from transformers[sentencepiece]==4.41.2) (5.29.6)\n","Requirement already satisfied: pyarrow>=15.0.0 in /usr/local/lib/python3.12/dist-packages (from datasets) (18.1.0)\n","Requirement already satisfied: dill<0.3.9,>=0.3.0 in /usr/local/lib/python3.12/dist-packages (from datasets) (0.3.8)\n","Requirement already satisfied: pandas in /usr/local/lib/python3.12/dist-packages (from datasets) (2.2.2)\n","Requirement already satisfied: xxhash in /usr/local/lib/python3.12/dist-packages (from datasets) (3.6.0)\n","Requirement already satisfied: multiprocess<0.70.17 in /usr/local/lib/python3.12/dist-packages (from datasets) (0.70.16)\n","Requirement already satisfied: fsspec<=2025.3.0,>=2023.1.0 in /usr/local/lib/python3.12/dist-packages (from fsspec[http]<=2025.3.0,>=2023.1.0->datasets) (2025.3.0)\n","Requirement already satisfied: aiohttp!=4.0.0a0,!=4.0.0a1 in /usr/local/lib/python3.12/dist-packages (from fsspec[http]<=2025.3.0,>=2023.1.0->datasets) (3.13.5)\n","Requirement already satisfied: hf-xet<2.0.0,>=1.1.3 in /usr/local/lib/python3.12/dist-packages (from huggingface-hub<1.0,>=0.23.0->transformers==4.41.2->transformers[sentencepiece]==4.41.2) (1.4.3)\n","Requirement already satisfied: typing-extensions>=3.7.4.3 in /usr/local/lib/python3.12/dist-packages (from huggingface-hub<1.0,>=0.23.0->transformers==4.41.2->transformers[sentencepiece]==4.41.2) (4.15.0)\n","Requirement already satisfied: charset_normalizer<4,>=2 in /usr/local/lib/python3.12/dist-packages (from requests->transformers==4.41.2->transformers[sentencepiece]==4.41.2) (3.4.7)\n","Requirement already satisfied: idna<4,>=2.5 in /usr/local/lib/python3.12/dist-packages (from requests->transformers==4.41.2->transformers[sentencepiece]==4.41.2) (3.13)\n","RLine truncated
|
||||||
+4141
-76
File diff suppressed because it is too large.
Load diff
@@ -22,5 +22,18 @@ print(f)
|
|||||||
print(g)
|
print(g)
|
||||||
print(h)
|
print(h)
|
||||||
|
|
||||||
|
# \n == enter
|
||||||
multiline = "Life is too short\n you need python"
|
multiline = "Life is too short\n you need python"
|
||||||
print(multiline)
|
print(multiline)
|
||||||
|
|
||||||
|
# import mod1
|
||||||
|
# print(mod1.add(5,3))
|
||||||
|
# print(mod1.sub(5,3))
|
||||||
|
|
||||||
|
# from mod1 import add
|
||||||
|
# print(add(3,7))
|
||||||
|
|
||||||
|
# * : 모두
|
||||||
|
from mod1 import *
|
||||||
|
print(add(3,7))
|
||||||
|
print(sub(3,7))
|
||||||
@@ -0,0 +1,500 @@
|
|||||||
|
파다 98 170
|
||||||
|
차카 63 194
|
||||||
|
바카 42 152
|
||||||
|
마파 62 157
|
||||||
|
라마 77 156
|
||||||
|
카다 40 143
|
||||||
|
가하 63 150
|
||||||
|
라가 78 153
|
||||||
|
라자 88 189
|
||||||
|
파다 47 186
|
||||||
|
파가 50 168
|
||||||
|
바타 59 194
|
||||||
|
파사 63 196
|
||||||
|
하차 87 195
|
||||||
|
마파 65 152
|
||||||
|
하파 62 145
|
||||||
|
차바 69 159
|
||||||
|
카차 70 196
|
||||||
|
바라 48 147
|
||||||
|
자나 43 146
|
||||||
|
파마 88 149
|
||||||
|
나나 67 155
|
||||||
|
파가 49 152
|
||||||
|
자차 96 140
|
||||||
|
사마 88 184
|
||||||
|
사바 90 174
|
||||||
|
나라 58 167
|
||||||
|
파나 66 152
|
||||||
|
타나 86 170
|
||||||
|
아나 93 195
|
||||||
|
사하 61 151
|
||||||
|
타하 85 142
|
||||||
|
카차 73 140
|
||||||
|
카마 90 157
|
||||||
|
가가 41 180
|
||||||
|
나나 56 198
|
||||||
|
다파 40 161
|
||||||
|
나카 62 170
|
||||||
|
차다 88 187
|
||||||
|
가자 45 150
|
||||||
|
사다 80 195
|
||||||
|
카바 84 192
|
||||||
|
하자 98 164
|
||||||
|
카자 92 177
|
||||||
|
다다 41 150
|
||||||
|
아타 86 170
|
||||||
|
마카 50 182
|
||||||
|
마자 72 175
|
||||||
|
사다 40 158
|
||||||
|
사아 93 174
|
||||||
|
가라 58 153
|
||||||
|
자아 77 196
|
||||||
|
아바 42 162
|
||||||
|
마하 56 175
|
||||||
|
파파 93 187
|
||||||
|
파마 91 172
|
||||||
|
카다 80 146
|
||||||
|
가다 95 166
|
||||||
|
카카 42 150
|
||||||
|
라차 50 191
|
||||||
|
아바 95 143
|
||||||
|
바마 91 175
|
||||||
|
파라 85 164
|
||||||
|
마라 85 168
|
||||||
|
자하 89 192
|
||||||
|
사아 99 197
|
||||||
|
사차 61 172
|
||||||
|
차차 76 162
|
||||||
|
다차 83 191
|
||||||
|
나타 63 150
|
||||||
|
하사 91 150
|
||||||
|
카사 59 162
|
||||||
|
카차 87 197
|
||||||
|
카바 61 181
|
||||||
|
바파 58 168
|
||||||
|
카타 93 200
|
||||||
|
나나 51 194
|
||||||
|
다가 92 169
|
||||||
|
가나 82 145
|
||||||
|
카파 77 177
|
||||||
|
타하 54 157
|
||||||
|
차바 44 165
|
||||||
|
사파 58 142
|
||||||
|
나카 83 157
|
||||||
|
다가 59 151
|
||||||
|
마카 45 144
|
||||||
|
마파 72 169
|
||||||
|
라아 54 188
|
||||||
|
타자 89 177
|
||||||
|
나나 48 198
|
||||||
|
파사 75 168
|
||||||
|
바다 95 157
|
||||||
|
아아 58 189
|
||||||
|
아가 72 174
|
||||||
|
카아 78 156
|
||||||
|
타바 50 168
|
||||||
|
다사 87 163
|
||||||
|
라다 83 145
|
||||||
|
다라 97 140
|
||||||
|
마가 88 143
|
||||||
|
라파 88 183
|
||||||
|
하카 51 199
|
||||||
|
자다 41 172
|
||||||
|
자하 70 175
|
||||||
|
마다 66 184
|
||||||
|
바자 93 173
|
||||||
|
가차 100 175
|
||||||
|
마아 62 151
|
||||||
|
파타 45 178
|
||||||
|
타라 80 165
|
||||||
|
마하 66 187
|
||||||
|
라카 50 182
|
||||||
|
카다 47 181
|
||||||
|
가가 51 144
|
||||||
|
파아 65 189
|
||||||
|
타자 67 160
|
||||||
|
카아 51 197
|
||||||
|
가라 79 151
|
||||||
|
자아 58 192
|
||||||
|
하하 44 152
|
||||||
|
카다 96 170
|
||||||
|
마라 84 176
|
||||||
|
마아 67 179
|
||||||
|
차다 67 147
|
||||||
|
아라 71 169
|
||||||
|
타라 50 154
|
||||||
|
바다 52 186
|
||||||
|
하차 40 145
|
||||||
|
파사 75 161
|
||||||
|
가다 66 147
|
||||||
|
라하 84 177
|
||||||
|
라바 53 163
|
||||||
|
다사 61 155
|
||||||
|
아바 57 192
|
||||||
|
마다 55 172
|
||||||
|
타카 81 159
|
||||||
|
타라 74 191
|
||||||
|
다차 62 142
|
||||||
|
가하 48 171
|
||||||
|
차바 94 166
|
||||||
|
나파 79 180
|
||||||
|
차사 80 140
|
||||||
|
하다 51 196
|
||||||
|
바나 54 148
|
||||||
|
마카 66 163
|
||||||
|
하나 78 169
|
||||||
|
마나 85 171
|
||||||
|
자마 74 152
|
||||||
|
파나 41 170
|
||||||
|
라나 88 149
|
||||||
|
다가 73 158
|
||||||
|
자아 78 163
|
||||||
|
아나 47 167
|
||||||
|
바마 54 144
|
||||||
|
사바 47 177
|
||||||
|
자타 58 156
|
||||||
|
차나 52 177
|
||||||
|
타카 69 174
|
||||||
|
사자 54 178
|
||||||
|
바나 49 143
|
||||||
|
라하 87 177
|
||||||
|
마차 73 199
|
||||||
|
아자 61 152
|
||||||
|
마파 41 177
|
||||||
|
카나 76 145
|
||||||
|
마타 57 194
|
||||||
|
차파 90 169
|
||||||
|
가아 58 194
|
||||||
|
나다 85 171
|
||||||
|
다라 89 171
|
||||||
|
다하 87 152
|
||||||
|
차나 71 147
|
||||||
|
바마 71 143
|
||||||
|
자가 64 176
|
||||||
|
파나 75 183
|
||||||
|
라파 99 185
|
||||||
|
라사 91 173
|
||||||
|
바다 59 191
|
||||||
|
자하 56 179
|
||||||
|
아나 79 163
|
||||||
|
마아 67 183
|
||||||
|
자파 99 198
|
||||||
|
마사 89 154
|
||||||
|
사다 90 190
|
||||||
|
타마 76 152
|
||||||
|
바가 82 176
|
||||||
|
마타 47 180
|
||||||
|
마하 93 200
|
||||||
|
아파 100 183
|
||||||
|
카가 81 178
|
||||||
|
바하 96 145
|
||||||
|
하마 61 185
|
||||||
|
바마 58 151
|
||||||
|
카사 100 179
|
||||||
|
마카 67 159
|
||||||
|
마나 74 195
|
||||||
|
하다 76 162
|
||||||
|
타자 69 177
|
||||||
|
바라 59 149
|
||||||
|
자파 58 181
|
||||||
|
바나 79 154
|
||||||
|
차아 91 163
|
||||||
|
카라 63 179
|
||||||
|
가카 60 197
|
||||||
|
가바 54 185
|
||||||
|
바나 58 157
|
||||||
|
차바 57 183
|
||||||
|
가사 66 163
|
||||||
|
바차 74 142
|
||||||
|
다파 56 183
|
||||||
|
아가 70 141
|
||||||
|
가차 46 141
|
||||||
|
라아 76 140
|
||||||
|
하타 70 158
|
||||||
|
다사 90 177
|
||||||
|
아자 54 152
|
||||||
|
라라 40 198
|
||||||
|
하다 77 164
|
||||||
|
가카 89 183
|
||||||
|
자하 94 145
|
||||||
|
가타 85 177
|
||||||
|
나아 92 162
|
||||||
|
다카 77 171
|
||||||
|
다마 88 156
|
||||||
|
바라 100 193
|
||||||
|
하카 55 194
|
||||||
|
자파 42 150
|
||||||
|
아자 82 155
|
||||||
|
마마 46 144
|
||||||
|
카가 96 147
|
||||||
|
마자 50 148
|
||||||
|
아라 47 160
|
||||||
|
카라 99 176
|
||||||
|
타바 56 186
|
||||||
|
타아 64 173
|
||||||
|
바파 86 192
|
||||||
|
마사 78 176
|
||||||
|
아파 62 193
|
||||||
|
카바 91 164
|
||||||
|
마타 62 161
|
||||||
|
마가 92 199
|
||||||
|
라바 50 177
|
||||||
|
라라 68 158
|
||||||
|
차파 40 176
|
||||||
|
타나 58 147
|
||||||
|
라하 83 158
|
||||||
|
자바 79 167
|
||||||
|
하아 53 140
|
||||||
|
다라 93 185
|
||||||
|
다나 78 184
|
||||||
|
아다 53 176
|
||||||
|
타다 55 146
|
||||||
|
하자 67 198
|
||||||
|
사바 47 149
|
||||||
|
타나 83 185
|
||||||
|
타자 43 194
|
||||||
|
파파 52 200
|
||||||
|
차타 84 144
|
||||||
|
가가 92 196
|
||||||
|
라하 47 144
|
||||||
|
차사 60 174
|
||||||
|
마타 65 179
|
||||||
|
다사 63 148
|
||||||
|
카아 79 142
|
||||||
|
라카 73 161
|
||||||
|
카아 92 141
|
||||||
|
라라 92 151
|
||||||
|
차카 71 183
|
||||||
|
하타 91 146
|
||||||
|
사사 82 194
|
||||||
|
바파 58 180
|
||||||
|
카가 40 176
|
||||||
|
차다 72 182
|
||||||
|
파가 95 163
|
||||||
|
파아 82 196
|
||||||
|
타가 40 143
|
||||||
|
나나 69 176
|
||||||
|
카카 98 171
|
||||||
|
차라 77 198
|
||||||
|
파바 54 140
|
||||||
|
다다 96 198
|
||||||
|
바파 77 141
|
||||||
|
자라 95 171
|
||||||
|
파마 90 178
|
||||||
|
다바 100 168
|
||||||
|
타타 94 187
|
||||||
|
타파 90 147
|
||||||
|
차사 43 142
|
||||||
|
자마 64 194
|
||||||
|
가파 89 192
|
||||||
|
파파 93 189
|
||||||
|
라가 48 182
|
||||||
|
마타 49 166
|
||||||
|
다타 84 157
|
||||||
|
타가 76 160
|
||||||
|
하자 46 140
|
||||||
|
자다 45 182
|
||||||
|
카타 49 162
|
||||||
|
카아 85 170
|
||||||
|
바자 56 157
|
||||||
|
아라 73 180
|
||||||
|
라아 98 200
|
||||||
|
아차 55 143
|
||||||
|
파라 58 149
|
||||||
|
파바 44 186
|
||||||
|
하자 83 197
|
||||||
|
아차 67 155
|
||||||
|
카하 51 169
|
||||||
|
하바 56 144
|
||||||
|
타카 91 155
|
||||||
|
차마 86 158
|
||||||
|
차아 96 154
|
||||||
|
다사 43 144
|
||||||
|
파다 70 200
|
||||||
|
나아 60 153
|
||||||
|
하아 69 194
|
||||||
|
하가 94 185
|
||||||
|
마가 51 168
|
||||||
|
가파 48 150
|
||||||
|
바바 68 191
|
||||||
|
나아 48 171
|
||||||
|
파아 45 140
|
||||||
|
바하 53 143
|
||||||
|
바파 68 154
|
||||||
|
차마 88 193
|
||||||
|
다타 88 167
|
||||||
|
차나 67 200
|
||||||
|
라바 76 185
|
||||||
|
바다 44 175
|
||||||
|
가마 64 166
|
||||||
|
바차 60 159
|
||||||
|
카라 88 150
|
||||||
|
자가 49 146
|
||||||
|
자가 75 165
|
||||||
|
가아 75 144
|
||||||
|
자라 75 143
|
||||||
|
마자 41 167
|
||||||
|
가차 81 160
|
||||||
|
다바 62 167
|
||||||
|
카바 71 168
|
||||||
|
타타 55 197
|
||||||
|
카자 44 200
|
||||||
|
아아 52 188
|
||||||
|
사사 59 155
|
||||||
|
가라 71 163
|
||||||
|
바사 44 189
|
||||||
|
가차 84 145
|
||||||
|
나자 67 190
|
||||||
|
차마 89 148
|
||||||
|
하마 89 183
|
||||||
|
다사 71 176
|
||||||
|
차가 97 200
|
||||||
|
다하 87 198
|
||||||
|
아가 56 170
|
||||||
|
사자 55 160
|
||||||
|
카자 77 169
|
||||||
|
파하 53 168
|
||||||
|
아사 95 172
|
||||||
|
차타 81 178
|
||||||
|
사차 42 145
|
||||||
|
나라 52 143
|
||||||
|
자아 45 145
|
||||||
|
다사 85 186
|
||||||
|
아자 77 151
|
||||||
|
타카 90 190
|
||||||
|
아나 59 152
|
||||||
|
라타 40 149
|
||||||
|
하타 64 168
|
||||||
|
하나 92 171
|
||||||
|
자타 56 198
|
||||||
|
사타 80 192
|
||||||
|
라다 68 193
|
||||||
|
타다 51 154
|
||||||
|
차가 57 193
|
||||||
|
라카 70 171
|
||||||
|
파나 87 143
|
||||||
|
하마 92 153
|
||||||
|
마바 52 198
|
||||||
|
카아 73 185
|
||||||
|
아라 87 176
|
||||||
|
다파 71 182
|
||||||
|
라자 55 166
|
||||||
|
마가 84 153
|
||||||
|
자사 79 195
|
||||||
|
나타 63 160
|
||||||
|
라사 52 194
|
||||||
|
타마 62 185
|
||||||
|
하자 93 152
|
||||||
|
바차 50 161
|
||||||
|
사자 99 141
|
||||||
|
바가 72 182
|
||||||
|
바나 88 181
|
||||||
|
차파 95 143
|
||||||
|
차다 69 145
|
||||||
|
라가 92 178
|
||||||
|
타파 97 180
|
||||||
|
마파 99 183
|
||||||
|
바타 97 146
|
||||||
|
라타 74 143
|
||||||
|
바아 40 162
|
||||||
|
사타 66 158
|
||||||
|
하자 92 182
|
||||||
|
차바 93 171
|
||||||
|
아하 42 177
|
||||||
|
다타 71 190
|
||||||
|
바가 72 186
|
||||||
|
마다 52 146
|
||||||
|
자다 88 181
|
||||||
|
라다 48 148
|
||||||
|
타마 40 152
|
||||||
|
파타 67 151
|
||||||
|
바차 70 158
|
||||||
|
차자 92 172
|
||||||
|
라마 96 153
|
||||||
|
하나 54 141
|
||||||
|
라라 60 167
|
||||||
|
하다 54 164
|
||||||
|
라파 79 155
|
||||||
|
파다 47 184
|
||||||
|
사하 92 186
|
||||||
|
다나 99 173
|
||||||
|
사타 43 188
|
||||||
|
타하 88 174
|
||||||
|
바바 70 175
|
||||||
|
아가 80 155
|
||||||
|
사카 72 186
|
||||||
|
라타 51 141
|
||||||
|
차마 74 144
|
||||||
|
라자 98 197
|
||||||
|
차가 71 167
|
||||||
|
가파 73 187
|
||||||
|
마마 79 146
|
||||||
|
아아 93 142
|
||||||
|
마하 53 164
|
||||||
|
가아 42 169
|
||||||
|
가차 62 142
|
||||||
|
바가 80 158
|
||||||
|
바자 99 149
|
||||||
|
라바 51 159
|
||||||
|
라아 69 143
|
||||||
|
타바 80 140
|
||||||
|
자하 76 186
|
||||||
|
바나 62 171
|
||||||
|
바아 82 167
|
||||||
|
하하 96 143
|
||||||
|
아파 53 145
|
||||||
|
타차 93 156
|
||||||
|
가다 41 171
|
||||||
|
바사 43 159
|
||||||
|
자라 57 181
|
||||||
|
다다 67 172
|
||||||
|
라카 67 162
|
||||||
|
다마 71 156
|
||||||
|
사카 48 186
|
||||||
|
가가 58 153
|
||||||
|
라라 54 166
|
||||||
|
아타 59 171
|
||||||
|
바라 61 174
|
||||||
|
자마 75 195
|
||||||
|
사타 82 166
|
||||||
|
라라 74 164
|
||||||
|
하바 47 183
|
||||||
|
나마 46 179
|
||||||
|
라사 40 190
|
||||||
|
마나 77 181
|
||||||
|
가가 52 145
|
||||||
|
자차 42 156
|
||||||
|
차나 76 157
|
||||||
|
자다 73 192
|
||||||
|
라다 93 194
|
||||||
|
나자 98 199
|
||||||
|
아카 84 194
|
||||||
|
나파 52 144
|
||||||
|
타차 82 191
|
||||||
|
가나 75 196
|
||||||
|
라다 48 170
|
||||||
|
자자 93 193
|
||||||
|
타다 48 196
|
||||||
|
차가 83 197
|
||||||
|
자하 76 165
|
||||||
|
하자 61 142
|
||||||
|
하타 74 199
|
||||||
|
타다 83 141
|
||||||
|
하카 58 150
|
||||||
|
자차 72 157
|
||||||
|
하가 47 156
|
||||||
|
마나 64 141
|
||||||
|
아파 65 162
|
||||||
|
다아 94 185
|
||||||
|
다아 68 164
|
||||||
|
타파 62 147
|
||||||
|
카바 57 183
|
||||||
|
하하 84 151
|
||||||
|
바하 92 140
|
||||||
|
자마 80 183
|
||||||
|
카나 59 193
|
||||||
|
사자 86 146
|
||||||
|
나차 88 168
|
||||||
|
다마 43 161
|
||||||
|
사타 86 149
|
||||||
@@ -0,0 +1,12 @@
|
|||||||
|
# 모듈 생성
|
||||||
|
def add(a, b):
|
||||||
|
return a + b
|
||||||
|
|
||||||
|
def sub(a, b):
|
||||||
|
return a - b
|
||||||
|
|
||||||
|
# 모듈 안 기능들이 잘 만들어졌는지 확인
|
||||||
|
# mod1 직접 실행될 때만 if문 실행
|
||||||
|
if __name__ == "__main__" :
|
||||||
|
print(add(3, 4))
|
||||||
|
print(sub(6, 4))
|
||||||
Binary file not shown.
@@ -0,0 +1,10 @@
|
|||||||
|
{
|
||||||
|
"name": "John Doe",
|
||||||
|
"age": 30,
|
||||||
|
"isStudent": false,
|
||||||
|
"hobbies": ["reading", "coding"]
|
||||||
|
"address": {
|
||||||
|
"city": "Seoul",
|
||||||
|
"zipcode": "12345"
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1 @@
|
|||||||
|
test
|
||||||
@@ -0,0 +1 @@
|
|||||||
|
{"name": "\ud64d\uae38\ub3d9", "birth": "0525", "age": 30}
|
||||||
@@ -0,0 +1,3 @@
|
|||||||
|
Line 1
|
||||||
|
Line 2
|
||||||
|
Line 3
|
||||||
@@ -0,0 +1,13 @@
|
|||||||
|
import gradio as gr
|
||||||
|
|
||||||
|
def greet(name, intensity):
|
||||||
|
return "Hello, " + name + "!" * int(intensity)
|
||||||
|
|
||||||
|
demo = gr.Interface(
|
||||||
|
fn=greet,
|
||||||
|
inputs=["text", "slider"],
|
||||||
|
outputs=["text"],
|
||||||
|
api_name="predict"
|
||||||
|
)
|
||||||
|
|
||||||
|
demo.launch()
|
||||||
Reference in new issue
Block a user