github bentoml/BentoML v1.0.15
BentoML - v1.0.15

latest releases: v1.3.11, v1.3.10, v1.3.9...
21 months ago

🍱 BentoML v1.0.15 release is here featuring the introduction of the bentoml.diffusers framework.

  • Learn more about the capabilities of the bentoml.diffusers framework in the Creating Stable Diffusion 2.0 Service With BentoML And Diffusers blog and BentoML Diffusers example project.

  • Import a diffusion model with the bentoml.diffusers.import_model API.

    import bentoml
    
    bentoml.diffusers.import_model(
        "sd2",
        "stabilityai/stable-diffusion-2",
    )
  • Create a text2img service using a Stable Diffusion 2.0 model runner with the familiar to_runner API from the bentoml.diffuser framework.

    import torch
    from diffusers import StableDiffusionPipeline
    
    import bentoml
    from bentoml.io import Image, JSON, Multipart
    
    bento_model = bentoml.diffusers.get("sd2:latest")
    stable_diffusion_runner = bento_model.to_runner()
    
    svc = bentoml.Service("stable_diffusion_v2", runners=[stable_diffusion_runner])
    
    @svc.api(input=JSON(), output=Image())
    def txt2img(input_data):
        images, _ = stable_diffusion_runner.run(**input_data)
        return images[0]

🍱 Fixed a incompatibility change introduced in starlette==0.25.0 result in the type MultiPartMessage not being found in starlette.formparsers.

ImportError: cannot import name 'MultiPartMessage' from 'starlette.formparsers' (/opt/miniconda3/envs/bentoml/lib/python3.10/site-packages/starlette/formparsers.py)

What's Changed

New Contributors

Full Changelog: v1.0.14...v1.0.15

Don't miss a new BentoML release

NewReleases is sending notifications on new releases.