Instructions to use 43ntropy/NEvo with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Diffusers
How to use 43ntropy/NEvo with Diffusers:
pip install -U diffusers transformers accelerate
import torch from diffusers import DiffusionPipeline # switch to "mps" for apple devices pipe = DiffusionPipeline.from_pretrained("43ntropy/NEvo", dtype=torch.bfloat16, device_map="cuda") prompt = "Astronaut in a jungle, cold color palette, muted colors, detailed, 8k" image = pipe(prompt).images[0] - Notebooks
- Google Colab
- Kaggle
| """NEvo custom Diffusers pipeline entry point. | |
| Works both when the ``stimulus_synthesis`` package is installed (``pip install``) and, | |
| off-the-shelf, when the pipeline is loaded via | |
| ``DiffusionPipeline.from_pretrained(repo, custom_pipeline=repo, trust_remote_code=True)`` | |
| without installing anything — in that case the package (and its bundled data) is | |
| fetched from the Hub and put on the import path. | |
| """ | |
| try: | |
| from stimulus_synthesis.pipeline import NevoPipeline | |
| except ModuleNotFoundError: | |
| import sys | |
| from huggingface_hub import snapshot_download | |
| _pkg_root = snapshot_download("epfl-neuroai/NEvo", allow_patterns=["stimulus_synthesis/**"]) | |
| if _pkg_root not in sys.path: | |
| sys.path.insert(0, _pkg_root) | |
| from stimulus_synthesis.pipeline import NevoPipeline | |
| __all__ = ["NevoPipeline"] | |