how to create custom architectures

you can read this blogpost to find out more ๐Ÿ“–

How to use

you can the model via the command

from transformers import AutoModelForImageClassification
model = AutoModelForImageClassification.from_pretrained("not-lain/MyRepo", trust_remote_code=True)

or you can use the pipeline

from transformers import pipeline
pipe = pipeline(model="not-lain/MyRepo", trust_remote_code=True)
pipe(
    "url",
    download=True, # will call the download_img method
    clean_output=False # will be passed as postprocess_kwargs
  )

parameters

the pipeline supports the following parameters :

  • download
  • clean_output

you can also use the following method to download images from the web

pipe.download_img(url)
Downloads last month
212
Safetensors
Model size
21.8k params
Tensor type
F32
ยท
Inference Providers NEW
This model is not currently available via any of the supported Inference Providers.
The model cannot be deployed to the HF Inference API: The HF Inference API does not support model that require custom code execution.