Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -1337,14 +1337,14 @@ def main():

coloredlogs.install(fmt="%(funcName)20s: %(message)s")

memory_monitor_type = "rocm" if args.provider == "rocm" else "cuda"
memory_monitor_type = "rocm" if args.provider == "rocm" or "migraphx" else "cuda"

start_memory = measure_gpu_memory(memory_monitor_type, None)
print("GPU memory used before loading models:", start_memory)

sd_model = SD_MODELS[args.version]
provider = PROVIDERS[args.provider]
if args.engine == "onnxruntime" and args.provider == "tensorrt":
if args.engine == "onnxruntime" and args.provider == "tensorrt" or args.provider == "migraphx":
if "xl" in args.version:
print("Testing Txt2ImgXLPipeline with static input shape. Backend is ORT TensorRT EP.")
result = run_ort_trt_xl(
Expand All @@ -1362,7 +1362,6 @@ def main():
max_batch_size=args.max_trt_batch_size,
nvtx_profile=False,
use_cuda_graph=args.enable_cuda_graph,
skip_warmup=args.skip_warmup,
)
else:
print("Testing Txt2ImgPipeline with static input shape. Backend is ORT TensorRT EP.")
Expand All @@ -1381,7 +1380,6 @@ def main():
max_batch_size=args.max_trt_batch_size,
nvtx_profile=False,
use_cuda_graph=args.enable_cuda_graph,
skip_warmup=args.skip_warmup,
)
elif args.engine == "optimum" and provider == "CUDAExecutionProvider":
if "xl" in args.version:
Expand Down
Original file line number Diff line number Diff line change
@@ -1,2 +1,24 @@
-r ../requirements.txt

huggingface_hub==0.25.2
diffusers==0.28.0
transformers==4.41.2
numpy>=1.24.1
accelerate
onnx==1.17.0
coloredlogs
packaging
# Use newer version of protobuf might cause crash
protobuf
psutil
sympy


mediapipe
controlnet_aux==0.0.9
# The following are for SDXL
optimum==1.20.0
safetensors
invisible_watermark
opencv-python-headless

# Install onnxruntime-rocm that is built from source (https://onnxruntime.ai/docs/build/eps.html#amd-rocm)
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
# Following is to ensure we're grab latest ROCm instance of packages (ROCm 6.4.1 in this case)
-i https://repo.radeon.com/rocm/manylinux/rocm-rel-6.4.1/
torchvision==0.15.2
onnxruntime-rocm
Loading