Skip to content

Commit

Permalink
Improve the artifact saving (#1904)
Browse files Browse the repository at this point in the history
  • Loading branch information
ydm-amazon authored May 14, 2024
1 parent 87440bb commit 8612d35
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
1 change: 1 addition & 0 deletions .github/workflows/run-max-num-tokens.yml
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,7 @@ jobs:
run: |
python3 llm/run_max_num_tokens.py "${{ inputs.running_template }}"
- name: Upload test logs
if: always()
uses: actions/upload-artifact@v3
with:
path: tests/integration/max_num_token_results/
Expand Down
5 changes: 2 additions & 3 deletions tests/integration/llm/run_max_num_tokens.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,9 +17,8 @@
json_str = [line.decode("utf-8").strip() for line in data][0]
model_tp_dict = json.loads(json_str)

log_id = 0
for model_id, tp_list in model_tp_dict.items():
model_name = model_id
model_name = os.path.basename(os.path.normpath(model_id))
print(f"Starting runs for model {model_name}:")
if model_id[:2] == 's3':
# download model
Expand Down Expand Up @@ -49,6 +48,6 @@
model, tp, max_tokens = max_token_finder(properties)
output = f"Summary:\nmodel: {model_name}\n tp: {tp}\n max_tokens: {max_tokens}"
print(output)
with open("max_num_token_results/" + str(log_id) + "_log.txt",
with open(f"max_num_token_results/{model_name}_{tp}_log.txt",
"w") as log_file:
log_file.write(output)

0 comments on commit 8612d35

Please sign in to comment.