not-lain commited on
Commit
6c6d533
1 Parent(s): a86cea4

Update app_parquet.py

Browse files
Files changed (1) hide show
  1. app_parquet.py +2 -2
app_parquet.py CHANGED
@@ -187,14 +187,14 @@ PARQUET_DATASET_DIR.mkdir(parents=True, exist_ok=True)
187
  scheduler = ParquetScheduler(repo_id="example-space-to-dataset-parquet")
188
 
189
  # client = Client("stabilityai/stable-diffusion") # Space is paused
190
- client = Client("runwayml/stable-diffusion-v1-5")
191
 
192
 
193
  def generate(prompt: str) -> tuple[str, list[str]]:
194
  """Generate images on 'submit' button."""
195
  # Generate from https://huggingface.co/spaces/stabilityai/stable-diffusion
196
  # out_dir = client.predict(prompt, "", 9, fn_index=1) # Space 'stabilityai/stable-diffusion' is paused
197
- out_dir = client.predict(prompt, fn_index=1)
198
  with (Path(out_dir) / "captions.json").open() as f:
199
  paths = list(json.load(f).keys())
200
 
 
187
  scheduler = ParquetScheduler(repo_id="example-space-to-dataset-parquet")
188
 
189
  # client = Client("stabilityai/stable-diffusion") # Space is paused
190
+ client = Client("black-forest-labs/FLUX.1-dev")
191
 
192
 
193
  def generate(prompt: str) -> tuple[str, list[str]]:
194
  """Generate images on 'submit' button."""
195
  # Generate from https://huggingface.co/spaces/stabilityai/stable-diffusion
196
  # out_dir = client.predict(prompt, "", 9, fn_index=1) # Space 'stabilityai/stable-diffusion' is paused
197
+ out_dir = client.predict(prompt, api_name="/infer")
198
  with (Path(out_dir) / "captions.json").open() as f:
199
  paths = list(json.load(f).keys())
200