major package upgrade&new weights

This commit is contained in:
rmaphoh
2025-02-19 13:34:23 +00:00
parent 70b56d34ec
commit c38dfeb77c
2 changed files with 10 additions and 9 deletions
+9 -7
View File
@@ -2,7 +2,7 @@
"cells": [
{
"cell_type": "code",
"execution_count": 14,
"execution_count": null,
"id": "0ae19951",
"metadata": {},
"outputs": [],
@@ -14,6 +14,7 @@
"import pandas as pd\n",
"from PIL import Image\n",
"import models_vit as models\n",
"from huggingface_hub import hf_hub_download\n",
"np.set_printoptions(threshold=np.inf)\n",
"np.random.seed(1)\n",
"torch.manual_seed(1)"
@@ -113,19 +114,20 @@
},
{
"cell_type": "code",
"execution_count": 21,
"execution_count": null,
"id": "54acfcd7",
"metadata": {},
"outputs": [],
"source": [
"chkpt_dir = '/home/jupyter/huggingface_repo/RETFound_dinov2_meh.pth'\n",
"data_path = '/home/jupyter/public_dataset/IDRiD_data/val/anoDR'\n",
"device = torch.device('cuda')"
"chkpt_dir = hf_hub_download(repo_id=\"YukunZhou/RETFound_dinov2_meh\", filename=\"RETFound_dinov2_meh.pth\")\n",
"data_path = 'DATA_PATH'\n",
"device = torch.device('cuda')\n",
"arch='dinov2_large'"
]
},
{
"cell_type": "code",
"execution_count": 22,
"execution_count": null,
"id": "0296f74e",
"metadata": {},
"outputs": [],
@@ -133,7 +135,7 @@
"[name_list,feature]=get_feature(data_path,\n",
" chkpt_dir,\n",
" device,\n",
" arch='dinov2_large')"
" arch=arch)"
]
},
{