{ "cells": [ { "cell_type": "code", "execution_count": 3, "id": "3ea1a0aa", "metadata": {}, "outputs": [ { "name": "stdout", "output_type": "stream", "text": [ "📥 Downloading U2Net weights...\n" ] }, { "name": "stderr", "output_type": "stream", "text": [ "Downloading...\n", "From (original): https://drive.google.com/uc?id=1ao1ovG1Qtx4b7EoskHXmi2E9rp5CHLcZ\n", "From (redirected): https://drive.google.com/uc?id=1ao1ovG1Qtx4b7EoskHXmi2E9rp5CHLcZ&confirm=t&uuid=8a06fcb1-4f4c-4512-ad76-ade52d5e570a\n", "To: C:\\Users\\HP\\NitroSense-AI\\u2net\\weights\\u2net.pth\n", "100%|███████████████████████████████████████████████████████████████████████████████| 176M/176M [00:19<00:00, 9.17MB/s]\n" ] }, { "name": "stdout", "output_type": "stream", "text": [ "✅ Weights downloaded to: u2net/weights/u2net.pth\n" ] } ], "source": [ "import gdown\n", "import os\n", "\n", "# Create weights folder if not exists\n", "os.makedirs('u2net/weights', exist_ok=True)\n", "\n", "# Download U2Net weights\n", "url = \"https://drive.google.com/uc?id=1ao1ovG1Qtx4b7EoskHXmi2E9rp5CHLcZ\"\n", "output = \"u2net/weights/u2net.pth\"\n", "\n", "print(\"📥 Downloading U2Net weights...\")\n", "gdown.download(url, output, quiet=False)\n", "print(\"✅ Weights downloaded to:\", output)" ] }, { "cell_type": "code", "execution_count": null, "id": "2f465fa7", "metadata": {}, "outputs": [], "source": [] } ], "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.11.5" } }, "nbformat": 4, "nbformat_minor": 5 }