From 40b514bd2107767104f03dfa6303e45dda96d7d3 Mon Sep 17 00:00:00 2001 From: Deyao Zhu Date: Wed, 19 Apr 2023 20:00:25 +0300 Subject: [PATCH] update readme to include the device statement for demo --- README.md | 2 +- demo.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 0f3f461..063af4f 100644 --- a/README.md +++ b/README.md @@ -81,7 +81,7 @@ in [eval_configs/minigpt4_eval.yaml](eval_configs/minigpt4_eval.yaml#L10) at Lin Try out our demo [demo.py](demo.py) on your local machine by running ``` -python demo.py --cfg-path eval_configs/minigpt4_eval.yaml +python demo.py --cfg-path eval_configs/minigpt4_eval.yaml --gpu-id 0 ``` Here, we load Vicuna as 8 bit by default to save some GPU memory usage. diff --git a/demo.py b/demo.py index 9e222d4..b3659f1 100644 --- a/demo.py +++ b/demo.py @@ -23,7 +23,7 @@ from minigpt4.tasks import * def parse_args(): parser = argparse.ArgumentParser(description="Demo") parser.add_argument("--cfg-path", required=True, help="path to configuration file.") - parser.add_argument("--gpu_id", type=int, default=0, help="specify the gpu to load the model.") + parser.add_argument("--gpu-id", type=int, default=0, help="specify the gpu to load the model.") parser.add_argument( "--options", nargs="+",