John6666 commited on
Commit
3f860f3
·
verified ·
1 Parent(s): b748322

Upload handler.py

Browse files
Files changed (1) hide show
  1. handler.py +3 -2
handler.py CHANGED
@@ -27,9 +27,10 @@ class EndpointHandler:
27
  #repo_id = "NoMoreCopyright/FLUX.1-dev-test"
28
  dtype = torch.bfloat16
29
  quantization_config = TorchAoConfig("int8wo")
30
- vae = AutoencoderKL.from_pretrained(repo_id, subfolder="vae", torch_dtype=dtype)
31
  #transformer = FluxTransformer2DModel.from_pretrained(repo_id, subfolder="transformer", torch_dtype=dtype, quantization_config=quantization_config).to("cuda")
32
- self.pipeline = FluxPipeline.from_pretrained(repo_id, vae=vae, torch_dtype=dtype, quantization_config=quantization_config)
 
33
  if IS_COMPILE: self.pipeline = compile_pipeline(self.pipeline)
34
  self.pipeline.to("cuda")
35
 
 
27
  #repo_id = "NoMoreCopyright/FLUX.1-dev-test"
28
  dtype = torch.bfloat16
29
  quantization_config = TorchAoConfig("int8wo")
30
+ #vae = AutoencoderKL.from_pretrained(repo_id, subfolder="vae", torch_dtype=dtype)
31
  #transformer = FluxTransformer2DModel.from_pretrained(repo_id, subfolder="transformer", torch_dtype=dtype, quantization_config=quantization_config).to("cuda")
32
+ #self.pipeline = FluxPipeline.from_pretrained(repo_id, vae=vae, torch_dtype=dtype, quantization_config=quantization_config)
33
+ self.pipeline = FluxPipeline.from_pretrained(repo_id, vae=None, torch_dtype=dtype, quantization_config=quantization_config)
34
  if IS_COMPILE: self.pipeline = compile_pipeline(self.pipeline)
35
  self.pipeline.to("cuda")
36