Skip to content

Commit

Permalink
minor fixes for comfyUI example (#876)
Browse files Browse the repository at this point in the history
  • Loading branch information
charlesfrye committed Sep 17, 2024
1 parent 97c6580 commit e69f543
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 5 deletions.
6 changes: 2 additions & 4 deletions 06_gpu_and_ml/comfyui/comfyapp.py
Original file line number Diff line number Diff line change
Expand Up @@ -36,15 +36,14 @@
#
# 2. In another terminal, run inference:
# ```bash
# python 06_gpu_and_ml/comfyui/comfyclient.py --dev --modal-workspace your-modal-workspace --prompt "your prompt here"
# python 06_gpu_and_ml/comfyui/comfyclient.py --dev --modal-workspace $(modal profile current) --prompt "neon green sign that says Modal"
# ```
# You can find your Modal workspace name by running `modal profile current`.
#
# The first inference will take ~1m since the container needs to launch the ComfyUI server and load Flux into memory. Successive inferences on a warm container should take a few seconds.
#
# ## Setup
#
# First, we define the environment we need to run ComfyUI using [comfy-cli](https://github.com/Comfy-Org/comfy-cli). This handy tool manages the installation of ComfyUI, its dependencies, models, and custom nodes.
# First, we define the environment we need to run ComfyUI using [`comfy-cli`](https://github.com/Comfy-Org/comfy-cli). This handy tool manages the installation of ComfyUI, its dependencies, models, and custom nodes.


import json
Expand Down Expand Up @@ -173,7 +172,6 @@ def api(self, item: Dict):
# When you run this script with `modal deploy 06_gpu_and_ml/comfyui/comfyapp.py`, you'll see a link that includes `ui`.
# Head there to interactively develop your ComfyUI workflow. All of your models and custom nodes specified in the image build step will be loaded in.
#
#
# To serve the workflow after you've developed it, first export it as "API Format" JSON:
# 1. Click the gear icon in the top-right corner of the menu
# 2. Select "Enable Dev mode Options"
Expand Down
2 changes: 1 addition & 1 deletion 06_gpu_and_ml/comfyui/comfyclient.py
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ def parse_args(arglist: list[str]) -> argparse.Namespace:
"--prompt",
type=str,
required=True,
help="what to draw in the blank part of the image",
help="Prompt for the image generation model.",
)
parser.add_argument(
"--dev",
Expand Down

0 comments on commit e69f543

Please sign in to comment.