Thomas Male commited on
Commit
3408f7d
·
verified ·
1 Parent(s): 35da4d4

Update handler.py

Browse files
Files changed (1) hide show
  1. handler.py +4 -4
handler.py CHANGED
@@ -69,7 +69,7 @@ class EndpointHandler():
69
 
70
  inputs = data.pop("inputs", data)
71
 
72
- if use_image:
73
  sampler = PointCloudSampler(
74
  device=device,
75
  models=[base_model, upsampler_model],
@@ -78,13 +78,13 @@ class EndpointHandler():
78
  aux_channels=['R', 'G', 'B'],
79
  guidance_scale=[3.0, 3.0],
80
  )
81
-
82
  # Load an image to condition on.
83
  image_data = base64.b64decode(image_data_encoded)
84
-
85
  # Convert bytes to PIL Image
86
  img = Image.open(BytesIO(image_data))
87
- else:
88
  sampler = PointCloudSampler(
89
  device=device,
90
  models=[self.base_model,self.upsampler_model],
 
69
 
70
  inputs = data.pop("inputs", data)
71
 
72
+ if use_image:
73
  sampler = PointCloudSampler(
74
  device=device,
75
  models=[base_model, upsampler_model],
 
78
  aux_channels=['R', 'G', 'B'],
79
  guidance_scale=[3.0, 3.0],
80
  )
81
+
82
  # Load an image to condition on.
83
  image_data = base64.b64decode(image_data_encoded)
84
+
85
  # Convert bytes to PIL Image
86
  img = Image.open(BytesIO(image_data))
87
+ else:
88
  sampler = PointCloudSampler(
89
  device=device,
90
  models=[self.base_model,self.upsampler_model],