Update submission.py
Browse files- submission.py +2 -1
submission.py
CHANGED
|
@@ -53,6 +53,7 @@ MODEL_NAME = "resnet18" # replace with your actual model architecture - resnet1
|
|
| 53 |
|
| 54 |
SUBMIT = True # set to True to enable submission
|
| 55 |
|
|
|
|
| 56 |
|
| 57 |
def die(msg):
|
| 58 |
print(f"{msg}", file=sys.stderr)
|
|
@@ -67,7 +68,7 @@ if SUBMIT:
|
|
| 67 |
with open(MODEL_PATH, "rb") as f:
|
| 68 |
files = {"file": (os.path.basename(MODEL_PATH), f, "application/x-pytorch")}
|
| 69 |
resp = requests.post(
|
| 70 |
-
f"{BASE_URL}/
|
| 71 |
headers={"X-API-Key": API_KEY},
|
| 72 |
files=files,
|
| 73 |
data={"model-name": MODEL_NAME},
|
|
|
|
| 53 |
|
| 54 |
SUBMIT = True # set to True to enable submission
|
| 55 |
|
| 56 |
+
TASK_ID = "03-robustness" # donot change
|
| 57 |
|
| 58 |
def die(msg):
|
| 59 |
print(f"{msg}", file=sys.stderr)
|
|
|
|
| 68 |
with open(MODEL_PATH, "rb") as f:
|
| 69 |
files = {"file": (os.path.basename(MODEL_PATH), f, "application/x-pytorch")}
|
| 70 |
resp = requests.post(
|
| 71 |
+
f"{BASE_URL}/submit/{TASK_ID}",
|
| 72 |
headers={"X-API-Key": API_KEY},
|
| 73 |
files=files,
|
| 74 |
data={"model-name": MODEL_NAME},
|