mrfakename / starvector-starvector-8b-im2svg

huggingface.co
Total runs: 6
24-hour runs: 0
7-day runs: 1
30-day runs: 0
Model's Last Updated: March 21 2025
text-generation

Introduction of starvector-starvector-8b-im2svg

Model Details of starvector-starvector-8b-im2svg

Model Card for StarVector

image/png

StarVector is a foundation model for generating Scalable Vector Graphics (SVG) code from images and text. It utilizes a Vision-Language Modeling architecture to understand both visual and textual inputs, enabling high-quality vectorization and text-guided SVG creation.

Model Details
Model Description

This is the model card for the StarVector model, a 🤗 transformers model. StarVector is a foundation model for generating Scalable Vector Graphics (SVG) code from images and text. It utilizes a Vision-Language Modeling architecture to understand both visual and textual inputs, enabling high-quality vectorization and text-guided SVG creation.

  • Developed by: ServiceNow Research, Mila - Quebec AI Institute, ETS, Montreal.
  • Shared by : Juan A Rodriguez, Abhay Puri, Shubham Agarwal, Issam H. Laradji, Sai Rajeswar, Pau Rodriguez, David Vazquez, Christopher Pal, Marco Pedersoli.
  • Model type: Vision-Language Model for SVG Generation.
  • Language(s) (NLP): English.
  • License: Apache 2.0
Model Architecture

The StarVector architecture integrates an image encoder and a Large Language Model (LLM) Adapter to generate SVG code from both image and text inputs. Images are first converted into embeddings using a Vision Transformer (ViT), after which the LLM Adapter maps these embeddings into the LLM's embedding space to create visual tokens. Text prompts are handled through the LLM’s tokenizer and embedder. This unified multimodal approach ensures precise and contextually rich SVG output.

Figure 2: StarVector Architecture
Figure 2: a) StarVector Architecture: StarVector projects images into embeddings via an image encoder, then maps these embeddings to the LLM hidden space using an LLM Adapter, generating Visual Tokens. Text conditioning is achieved with the LLM's tokenizer and embedder. The model learns to map token sequences (visual or textual) to SVG code. The symbol ⊕ denotes mutually exclusive operations (image-to- SVG or text-to-SVG), while ‖ indicates sequence concatenation. Figure 2: b)Vision Model and Adapter: The image encoder employs a Vision Transformer (ViT) to process image patches sequentially. The LLM Adapter non-linearly projects embeddings into visual tokens for LLM integration.
Model Sources
Uses
Direct Use

Image-to-SVG generation, Text-to-SVG generation.

Downstream Use

Creation of icons, logotypes, technical diagrams, and other vector graphics.

Out-of-Scope Use

Generating realistic photographic images or complex 3D graphics.

Bias, Risks, and Limitations

Potential biases may exist in the model due to the composition of the training data (SVG-Stack). The model's ability to perfectly vectorize all types of images and interpret all textual instructions may have limitations. Users should be aware of these potential issues, especially in critical applications.

Recommendations

Users (both direct and downstream) should be made aware of the risks, biases and limitations of the model. Further investigation into the model's behavior across different types of inputs is recommended.

How to Get Started with the Model

Use the code below to get started with the model.

from PIL import Image
from transformers import AutoModelForCausalLM, AutoTokenizer, AutoProcessor
from starvector.data.util import process_and_rasterize_svg
import torch
 
model_name = "starvector/starvector-8b-im2svg"
 
starvector = AutoModelForCausalLM.from_pretrained(model_name, torch_dtype=torch.float16, trust_remote_code=True)
processor = starvector.model.processor
tokenizer = starvector.model.svg_transformer.tokenizer
 
starvector.cuda()
starvector.eval()
 
image_pil = Image.open('assets/examples/sample-18.png')
 
image = processor(image_pil, return_tensors="pt")['pixel_values'].cuda()
if not image.shape[0] == 1:
    image = image.squeeze(0)
batch = {"image": image}
 
raw_svg = starvector.generate_im2svg(batch, max_length=4000)[0]
svg, raster_image = process_and_rasterize_svg(raw_svg)
Training Details
Training Data

SVG-Stack: A dataset of over 2 million SVG samples.

Training Procedure

The model utilizes a Vision-Language Modeling architecture. Images are projected into embeddings via an image encoder, then mapped to the LLM hidden space using an LLM Adapter, generating Visual Tokens. Text conditioning is achieved with the LLM's tokenizer and embedder. The model learns to map token sequences (visual or textual) to SVG code.

Evaluation
Testing Data & Factors
Testing Data

SVG-Bench

Factors

SVG-Stack, SVG-Fonts, SVG-Icons, SVG-Emoji, SVG-Diagrams.

Models

StarVector models achieve state-of-the-art performance on SVG generation tasks

We provide Hugging Face 🤗 model checkpoints for image2SVG vectorization, for 💫 StarVector-8B and 💫 StarVector-1B. These are the results on SVG-Bench, using the DinoScore metric.

Method SVG-Stack SVG-Fonts SVG-Icons SVG-Emoji SVG-Diagrams
AutoTrace 0.942 0.954 0.946 0.975 0.874
Potrace 0.898 0.967 0.972 0.882 0.875
VTracer 0.954 0.964 0.940 0.981 0.882
Im2Vec 0.692 0.733 0.754 0.732 -
LIVE 0.934 0.956 0.959 0.969 0.870
DiffVG 0.810 0.821 0.952 0.814 0.822
GPT-4-V 0.852 0.842 0.848 0.850 -
💫 StarVector-1B 0.926 0.978 0.975 0.929 0.943
💫 StarVector-8B 0.966 0.982 0.984 0.981 0.959

Note: StarVector models will not work for natural images or illustrations, as they have not been trained on those images. They excel in vectorizing icons, logotypes, technical diagrams, graphs, and charts.

As shown in the table above, StarVector-8B achieves the highest performance across all benchmark datasets, demonstrating its effectiveness in generating high-quality SVG code from images. The model's ability to understand and reproduce complex vector graphics makes it particularly valuable for applications requiring precise vectorization of icons, logos, and technical diagrams.

Summary

StarVector represents a significant advancement in the field of vector graphics generation. By combining the power of vision-language models with a comprehensive training dataset, we've created a system that can accurately translate images into high-quality SVG code. The model's performance on SVG-Bench demonstrates its effectiveness across a wide range of vector graphics tasks.

We believe that StarVector will enable new applications in design, illustration, and technical documentation, making vector graphics more accessible and easier to create. We invite the research community to build upon our work and explore new directions in this exciting field.

For more details, please refer to our paper and explore our code repository.

BibTeX entry and citation info
@misc{rodriguez2024starvector,
      title={StarVector: Generating Scalable Vector Graphics Code from Images and Text},
      author={Juan A. Rodriguez and Abhay Puri and Shubham Agarwal and Issam H. Laradji and Pau Rodriguez and Sai Rajeswar and David Vazquez and Christopher Pal and Marco Pedersoli},
      year={2024},
      eprint={2312.11556},
      archivePrefix={arXiv},
      primaryClass={cs.CV},
      url={https://arxiv.org/abs/2312.11556},
}

Runs of mrfakename starvector-starvector-8b-im2svg on huggingface.co

6
Total runs
0
24-hour runs
0
3-day runs
1
7-day runs
0
30-day runs

More Information About starvector-starvector-8b-im2svg huggingface.co Model

More starvector-starvector-8b-im2svg license Visit here:

https://choosealicense.com/licenses/apache-2.0

starvector-starvector-8b-im2svg huggingface.co

starvector-starvector-8b-im2svg huggingface.co is an AI model on huggingface.co that provides starvector-starvector-8b-im2svg's model effect (), which can be used instantly with this mrfakename starvector-starvector-8b-im2svg model. huggingface.co supports a free trial of the starvector-starvector-8b-im2svg model, and also provides paid use of the starvector-starvector-8b-im2svg. Support call starvector-starvector-8b-im2svg model through api, including Node.js, Python, http.

starvector-starvector-8b-im2svg huggingface.co Url

https://huggingface.co/mrfakename/starvector-starvector-8b-im2svg

mrfakename starvector-starvector-8b-im2svg online free

starvector-starvector-8b-im2svg huggingface.co is an online trial and call api platform, which integrates starvector-starvector-8b-im2svg's modeling effects, including api services, and provides a free online trial of starvector-starvector-8b-im2svg, you can try starvector-starvector-8b-im2svg online for free by clicking the link below.

mrfakename starvector-starvector-8b-im2svg online free url in huggingface.co:

https://huggingface.co/mrfakename/starvector-starvector-8b-im2svg

starvector-starvector-8b-im2svg install

starvector-starvector-8b-im2svg is an open source model from GitHub that offers a free installation service, and any user can find starvector-starvector-8b-im2svg on GitHub to install. At the same time, huggingface.co provides the effect of starvector-starvector-8b-im2svg install, users can directly use starvector-starvector-8b-im2svg installed effect in huggingface.co for debugging and trial. It also supports api for free installation.

starvector-starvector-8b-im2svg install url in huggingface.co:

https://huggingface.co/mrfakename/starvector-starvector-8b-im2svg

Url of starvector-starvector-8b-im2svg

starvector-starvector-8b-im2svg huggingface.co Url

Provider of starvector-starvector-8b-im2svg huggingface.co

mrfakename
ORGANIZATIONS

Other API from mrfakename

huggingface.co

Total runs: 34
Run Growth: 0
Growth Rate: 0.00%
Updated:December 01 2025
huggingface.co

Total runs: 22
Run Growth: 19
Growth Rate: 86.36%
Updated:April 24 2024
huggingface.co

Total runs: 10
Run Growth: -1
Growth Rate: -10.00%
Updated:May 24 2026
huggingface.co

Total runs: 6
Run Growth: 4
Growth Rate: 66.67%
Updated:April 23 2025
huggingface.co

Total runs: 0
Run Growth: 0
Growth Rate: 0.00%
Updated:November 25 2025
huggingface.co

Total runs: 0
Run Growth: 0
Growth Rate: 0.00%
Updated:October 30 2025