Spaces:
Running
Running
Update app.py
Browse files
app.py
CHANGED
@@ -19,8 +19,8 @@ cookie_manager = stx.CookieManager()
|
|
19 |
|
20 |
@st.cache_resource
|
21 |
def get_vision_model():
|
22 |
-
model = AutoModelForVision2Seq.from_pretrained("
|
23 |
-
processor = AutoProcessor.from_pretrained("
|
24 |
return model, processor
|
25 |
|
26 |
# Function to get image caption via Kosmos2.
|
|
|
19 |
|
20 |
@st.cache_resource
|
21 |
def get_vision_model():
|
22 |
+
model = AutoModelForVision2Seq.from_pretrained("microsoft/kosmos-2-patch14-224")
|
23 |
+
processor = AutoProcessor.from_pretrained("microsoft/kosmos-2-patch14-224")
|
24 |
return model, processor
|
25 |
|
26 |
# Function to get image caption via Kosmos2.
|