mirror of
https://github.com/SakanaAI/doc-to-lora.git
synced 2026-07-23 17:01:04 +02:00
Update demo.ipynb with user structural edits
This commit is contained in:
parent
efd61538aa
commit
2ba3c1bd40
1 changed files with 22 additions and 11 deletions
33
demo.ipynb
33
demo.ipynb
|
|
@ -12,11 +12,11 @@
|
|||
"\n",
|
||||
"All model architectures, helper functions, and dependencies are defined directly within this notebook so it can run independently of the main repository codebase.\n",
|
||||
"\n",
|
||||
"### \ud83d\udd17 Project Resources\n",
|
||||
"- [**\ud83c\udf10 Project Website**](https://video2lora.github.io/)\n",
|
||||
"- [**\ud83d\udcc4 arXiv Paper**](https://arxiv.org/abs/2606.04351)\n",
|
||||
"- [**\ud83e\udd17 Hugging Face Checkpoints**](https://huggingface.co/MananSuri27/Video2LoRA-SmolVLM-ckpts)\n",
|
||||
"- [**\ud83d\udcbb GitHub Repository**](https://github.com/MananSuri27/video2lora)"
|
||||
"### 🔗 Project Resources\n",
|
||||
"- [**🌐 Project Website**](https://video2lora.github.io/)\n",
|
||||
"- [**📄 arXiv Paper**](https://arxiv.org/abs/2606.04351)\n",
|
||||
"- [**🤗 Hugging Face Checkpoints**](https://huggingface.co/MananSuri27/Video2LoRA-SmolVLM-ckpts)\n",
|
||||
"- [**💻 GitHub Repository**](https://github.com/MananSuri27/video2lora)"
|
||||
]
|
||||
},
|
||||
{
|
||||
|
|
@ -188,8 +188,15 @@
|
|||
" \"prompt\": \"Which parts of the creature are highlighted in the video? Answer only the question, in one sentence.\",\n",
|
||||
" \"target_text\": \"A close-up of its face, eyes, and hair.\"\n",
|
||||
" }\n",
|
||||
"]\n",
|
||||
"\n",
|
||||
"]"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "code",
|
||||
"execution_count": null,
|
||||
"metadata": {},
|
||||
"outputs": [],
|
||||
"source": [
|
||||
"import os\n",
|
||||
"import urllib.request\n",
|
||||
"\n",
|
||||
|
|
@ -374,7 +381,8 @@
|
|||
" \"content\": [\n",
|
||||
" {\"type\": \"video\", \"path\": example[\"video_path\"]},\n",
|
||||
" {\"type\": \"text\", \"text\": train_args.internalization_prompt}\n",
|
||||
" ]\n }\n",
|
||||
" ]\n",
|
||||
" }\n",
|
||||
" ]\n",
|
||||
" ]\n",
|
||||
"\n",
|
||||
|
|
@ -442,7 +450,8 @@
|
|||
" \"content\": [\n",
|
||||
" {\"type\": \"video\", \"path\": example[\"video_path\"]},\n",
|
||||
" {\"type\": \"text\", \"text\": example[\"prompt\"]}\n",
|
||||
" ]\n }\n",
|
||||
" ]\n",
|
||||
" }\n",
|
||||
" ]\n",
|
||||
" ]\n",
|
||||
"\n",
|
||||
|
|
@ -482,7 +491,9 @@
|
|||
" [\n",
|
||||
" {\n",
|
||||
" \"role\": \"user\",\n",
|
||||
" \"content\": [{\"type\": \"text\", \"text\": example[\"prompt\"]}]\n }\n ],\n",
|
||||
" \"content\": [{\"type\": \"text\", \"text\": example[\"prompt\"]}]\n",
|
||||
" }\n",
|
||||
" ],\n",
|
||||
" tokenize=True,\n",
|
||||
" add_generation_prompt=True,\n",
|
||||
" return_tensors=\"pt\"\n",
|
||||
|
|
@ -623,4 +634,4 @@
|
|||
},
|
||||
"nbformat": 4,
|
||||
"nbformat_minor": 2
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue