Spaces:
Runtime error
Runtime error
DiningSystem
commited on
Commit
•
43f22ca
1
Parent(s):
d38a8e1
Update app.py
Browse files
app.py
CHANGED
@@ -7,6 +7,8 @@ import torch
|
|
7 |
import torch.backends.cudnn as cudnn
|
8 |
import gradio as gr
|
9 |
|
|
|
|
|
10 |
from minigpt4.common.config import Config
|
11 |
from minigpt4.common.dist_utils import get_rank
|
12 |
from minigpt4.common.registry import registry
|
@@ -19,6 +21,8 @@ from minigpt4.processors import *
|
|
19 |
from minigpt4.runners import *
|
20 |
from minigpt4.tasks import *
|
21 |
|
|
|
|
|
22 |
def parse_args():
|
23 |
parser = argparse.ArgumentParser(description="Demo")
|
24 |
parser.add_argument("--cfg-path", type=str, default='eval_configs/minigpt4.yaml', help="path to configuration file.")
|
|
|
7 |
import torch.backends.cudnn as cudnn
|
8 |
import gradio as gr
|
9 |
|
10 |
+
import huggingface_hub as hf
|
11 |
+
|
12 |
from minigpt4.common.config import Config
|
13 |
from minigpt4.common.dist_utils import get_rank
|
14 |
from minigpt4.common.registry import registry
|
|
|
21 |
from minigpt4.runners import *
|
22 |
from minigpt4.tasks import *
|
23 |
|
24 |
+
hf.login(token=os.environ['model_token'])
|
25 |
+
|
26 |
def parse_args():
|
27 |
parser = argparse.ArgumentParser(description="Demo")
|
28 |
parser.add_argument("--cfg-path", type=str, default='eval_configs/minigpt4.yaml', help="path to configuration file.")
|