MCPcopy Create free account
hub / github.com/evilsocket/cake / load

Method load

cake-core/src/models/sd/unet.rs:25–41  ·  view source on GitHub ↗
(_name: String, ctx: &Context)

Source from the content-addressed store, hash-verified

23#[async_trait]
24impl Forwarder for UNet {
25 fn load(_name: String, ctx: &Context) -> anyhow::Result<Box<Self>>
26 where
27 Self: Sized,
28 {
29 let sd_config = get_sd_config(ctx)?;
30
31 Self::load_model(
32 ctx.args.sd_args.unet.clone(),
33 ctx.args.sd_args.use_flash_attention,
34 ctx.args.sd_args.sd_version,
35 ctx.args.sd_args.use_f16,
36 &ctx.device,
37 ctx.dtype,
38 ctx.args.model.clone(),
39 &sd_config,
40 )
41 }
42
43 async fn forward(
44 &self,

Callers

nothing calls this directly

Calls 2

get_sd_configFunction · 0.85
cloneMethod · 0.45

Tested by

no test coverage detected