Compare commits
2 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
85c456afe0 | ||
|
|
b3b52848c2 |
9
main.py
9
main.py
@@ -195,7 +195,8 @@ def check_platform_verify(model_id: str) -> dict:
|
||||
resp = requests.get(url, headers=headers, params={'modelId': model_id}, timeout=10)
|
||||
data = resp.json()
|
||||
if data.get('code') == 0:
|
||||
return data.get('data', {}).get('verifyResult', {})
|
||||
result = data.get('data', {}).get('verifyResult', {})
|
||||
return result if isinstance(result, dict) else {}
|
||||
except Exception:
|
||||
pass
|
||||
return {}
|
||||
@@ -301,9 +302,7 @@ def build_config_params(gpu: str) -> str:
|
||||
'gpu_num': 1,
|
||||
'command': [
|
||||
'/bin/bash', '-ic',
|
||||
'vllm serve /model --port 8000 --served-model-name llm '
|
||||
'--max-model-len 2048 --dtype auto --gpu-memory-utilization 0.95 '
|
||||
'-tp 1 --enforce-eager --trust-remote-code'
|
||||
'vllm serve /model --port 8000 --served-model-name llm --max-model-len 2048 --dtype auto --gpu-memory-utilization 0.95 -tp 1 --enforce-eager --trust-remote-code'
|
||||
]
|
||||
}
|
||||
},
|
||||
@@ -320,7 +319,7 @@ def build_config_params(gpu: str) -> str:
|
||||
},
|
||||
'model': 'llm',
|
||||
}
|
||||
return yaml.dump(params, default_flow_style=False, allow_unicode=True)
|
||||
return yaml.dump(params, default_flow_style=False, allow_unicode=True, width=1000)
|
||||
|
||||
|
||||
def submit_model(model_url: str, gpu: str, token: str) -> tuple:
|
||||
|
||||
Reference in New Issue
Block a user