Code Monkey home page Code Monkey logo

magespace-importer's Introduction

magespace_importer

magespace_importer is a Python-based tool designed to simplify importing models from a list of URLs into mage.space

It opens each URL in a new browser tab, and lets you perform the model import there. After you've imported a model, close the tab. To finish processing, close all browser tabs.

Installation

Ensure Python 3.10 or higher is installed on your system. You can then install the package using pip:

python3 -m pip install --upgrade git+https://github.com/twardoch/magespace-importer

Usage

Prepare a text file containing a list of URLs to models you want to import, one URL per line, and save it as magespace.txt in your current folder.

For example, for models from CivitAI, you can use URLs like:

https://civitai.com/api/download/models/243915?type=Model&format=SafeTensor&size=pruned&fp=fp16
https://civitai.com/api/download/models/163063?type=Model&format=SafeTensor

Note: If a model page on CivitAI has one Download button, you can use the CivitAI model page URL. But if the model page has a download dropdown, you must click it and copy the download URL (typically SafeTensors).

Then, use the tool in command line with optional arguments:

magespace_importer

The tool will open a new Chrome browser window where you'll need to log into https://mage.space/ using your credentials, then click the Terminal window and press Enter.

Then the tool open each URL in a new tab. You can then manually finalize the import in each tab. After you've imported a model, close the tab. To finish processing, close all browser tabs.

Optional Arguments

  • --models_path: Path to the text file containing model URLs (one URL per line), defaults to magespace.txt in the current folder.
  • --driver_path: Optional path to the ChromeDriver executable.
  • --url_import: Custom URL for the model import page, defaults to https://www.mage.space/models/import.

Example:

magespace_importer --models_path /path/to/magespace.txt

or if magespace.txt is in the current folder:

magespace_importer

magespace-importer's People

Contributors

twardoch avatar

Stargazers

 avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.