├── AUTOLYCUS.ipynb ├── README.md └── first_order_model_demo.ipynb /AUTOLYCUS.ipynb: -------------------------------------------------------------------------------- 1 | { 2 | "cells": [ 3 | { 4 | "cell_type": "markdown", 5 | "metadata": { 6 | "colab_type": "text", 7 | "id": "view-in-github" 8 | }, 9 | "source": [ 10 | "\"Open" 11 | ] 12 | }, 13 | { 14 | "cell_type": "markdown", 15 | "metadata": { 16 | "colab_type": "text", 17 | "id": "k2iDzwB9QeGW" 18 | }, 19 | "source": [ 20 | "#Welcome to **AUTOLYCUS** \n", 21 | "The Torrent to Drive Downloader tool \n", 22 | "\n", 23 | "> For more visit CrazyCoder009 >> https://github.com/CrazyCoder009\n", 24 | "\n" 25 | ] 26 | }, 27 | { 28 | "cell_type": "code", 29 | "execution_count": null, 30 | "metadata": { 31 | "colab": {}, 32 | "colab_type": "code", 33 | "id": "qJtAcvAlOdfK" 34 | }, 35 | "outputs": [], 36 | "source": [ 37 | "#adding corrections as suggested by SnazzyCoder (apologies for the late implementation)\n", 38 | "!python -m pip install --upgrade pip setuptools wheel\n", 39 | "!python -m pip install lbry-libtorrent\n", 40 | "\n", 41 | "#Run the program by clicking the left run button. \n", 42 | "\n", 43 | "!apt install python3-libtorrent\n", 44 | "# you can comment the upper !apt line if this is not your first time running this code (psst! reduces waiting time)\n", 45 | "\n", 46 | "import libtorrent as lt\n", 47 | "\n", 48 | "ses = lt.session()\n", 49 | "ses.listen_on(6881, 6891)\n", 50 | "downloads = []\n", 51 | "\n", 52 | "# Code for Connecting your Google Drive \n", 53 | "from google.colab import drive\n", 54 | "print(\" \")\n", 55 | "print(\"Click on the generated link to select Destination Drive:\")\n", 56 | "drive.mount(\"/content/drive\")\n", 57 | "\n", 58 | "# Code for Magnet URL Input of \n", 59 | "print(\"Drive Connected Successfully! \")\n", 60 | "print(\" \")\n", 61 | "params = {\"save_path\": \"/content/drive/My Drive/Torrent\"}\n", 62 | "\n", 63 | "while True:\n", 64 | " magnet_link = input(\"Enter Magnet/Download Link Or Type Exit: \")\n", 65 | " if magnet_link.lower() == \"exit\":\n", 66 | " break\n", 67 | " downloads.append(\n", 68 | " lt.add_magnet_uri(ses, magnet_link, params)\n", 69 | " )\n", 70 | "#Actual download Process Threads Code\n", 71 | "\n", 72 | "import time\n", 73 | "from IPython.display import display\n", 74 | "import ipywidgets as widgets\n", 75 | "\n", 76 | "state_str = [\n", 77 | " \"queued\",\n", 78 | " \"Apun checking karelai.. \",\n", 79 | " \"downloading metadata\",\n", 80 | " \"downloading bhai, wait karneka.. \",\n", 81 | " \"finished\",\n", 82 | " \"seeding\",\n", 83 | " \"allocating\",\n", 84 | " \"checking fastresume\",\n", 85 | "]\n", 86 | "\n", 87 | "layout = widgets.Layout(width=\"auto\")\n", 88 | "style = {\"description_width\": \"initial\"}\n", 89 | "download_bars = [\n", 90 | " widgets.FloatSlider(\n", 91 | " step=0.01, disabled=True, layout=layout, style=style\n", 92 | " )\n", 93 | " for _ in downloads\n", 94 | "]\n", 95 | "display(*download_bars)\n", 96 | "\n", 97 | "while downloads:\n", 98 | " next_shift = 0\n", 99 | " for index, download in enumerate(downloads[:]):\n", 100 | " bar = download_bars[index + next_shift]\n", 101 | " if not download.is_seed():\n", 102 | " s = download.status()\n", 103 | "\n", 104 | " bar.description = \" \".join(\n", 105 | " [\n", 106 | " download.name(),\n", 107 | " str(s.download_rate / 1000),\n", 108 | " \"kB/s\",\n", 109 | " state_str[s.state],\n", 110 | " ]\n", 111 | " )\n", 112 | " bar.value = s.progress * 100\n", 113 | " else:\n", 114 | " next_shift -= 1\n", 115 | " ses.remove_torrent(download)\n", 116 | " downloads.remove(download)\n", 117 | " bar.close() \n", 118 | " download_bars.remove(bar)\n", 119 | " print(download.name(), \"Complete\")\n", 120 | " time.sleep(1)\n", 121 | "\n", 122 | "#RRN\n", 123 | "#GitHub.com/CrazyCoder009\n" 124 | ] 125 | }, 126 | { 127 | "cell_type": "markdown", 128 | "metadata": { 129 | "colab_type": "text", 130 | "id": "qpcZ_U8iQner" 131 | }, 132 | "source": [ 133 | "**Disclaimer**: I'm not responsible for any damages or activities related to mis-management of this code or program. Hence use at your own risk. I've made this only for Research purposes." 134 | ] 135 | } 136 | ], 137 | "metadata": { 138 | "accelerator": "TPU", 139 | "colab": { 140 | "authorship_tag": "ABX9TyNhmFuKMcWiaDPoDismUvp0", 141 | "collapsed_sections": [], 142 | "include_colab_link": true, 143 | "name": "AUTOLYCUS.ipynb", 144 | "provenance": [] 145 | }, 146 | "kernelspec": { 147 | "display_name": "Python 3", 148 | "name": "python3" 149 | } 150 | }, 151 | "nbformat": 4, 152 | "nbformat_minor": 0 153 | } 154 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # Autolycus 2 | Can't go out this Corona Season? Autolycus is here! 3 | A simple and quick Torrent to Google Drive Dowloader using Google Colab. 4 | 5 | To access Autolycus click HERE: 6 | 7 | 8 | Open In Colab 9 | 10 | 11 | OR 12 | 13 | Just Navigate to this Link: 14 | 15 | https://colab.research.google.com/gist/CrazyCoder009/3ae848f93572cf324307aadcfa4563ca/qgdd.ipynb 16 | 17 | 18 | # Instructions to use Autolycus: 19 | 20 | 1. Copy Magnet Link of the Item of download from piratesbay/etc. 21 | 22 | 2. Click on 23 | Open In Colab 24 | . 25 | 26 | ## 3. Login using your SRMIST/Google account (any would work in this step, refer point 1 from limitations below). 27 | 28 | 4. Run the Program Code scroll down and wait. 29 | 30 | ## 5. Click on the generated link and login using your SRMIST Drive Account (for unlimited storage, yes it is unlimited). 31 | 32 | 6. Verify and click on "Allow", after that copy the generated verification code and come back to Autolycus and paste it in the field. 33 | 34 | 7. Hit Enter! 35 | 36 | 8. Paste your Magnet Links one by one, Hit enter! 37 | 38 | 9. When done pasting all, type "Exit" and Hit Enter! 39 | 40 | 10. Wait for the file to be downloaded to your drive. 41 | 42 | 11. DONE! Now you can view it directly from your Drive account, Phone, Laptop, etc., if not streamable instantly wait for 15 mins and then try to stream. (Drive takes time to process the file for streaming) 43 | 44 | 45 | # Precautions and Limitations: 46 | 47 | 1. Downloading using the same account everyday would lead to a temporary ban of 24hrs from Google Collab, so try using different accounts everyday (your gmail or srmist alternatively). 48 | 49 | 2. Changing the runtime type may give you more or less downloading memory depending on which you select, hence best to leave the runtime configurations to default if you're a noob.(107 GB Limit of download at once, plenty bruh!). 50 | 51 | 52 | # More Tools coming up! 53 | Be safe, stay safe this Corona Season. 54 | # RRN 55 | # www.github.com/CrazyCoder009 56 | 57 | --------------------------------------------------------------------------------