Skip to content

Instantly share code, notes, and snippets.

View yiwenlu66's full-sized avatar

Yiwen Lu yiwenlu66

View GitHub Profile
@yiwenlu66
yiwenlu66 / coalesce0.jsonl
Created January 26, 2026 13:43
issue #129: Qwen3-30B-A3B TP=4 single-node LoRA /asample reduced sweep (coalesce0 vs coalesce1) pl=32000 mt=256
{"base_url": "http://localhost:8000", "create_training_client_s": 0.31418959295842797, "filler_id": 264, "gen_max_tokens": 256, "git_sha": "6bbdb94175ac7ccd6675af3a3baec4f80c3392ff", "kind": "meta", "label": "coalesce0", "model": "Qwen/Qwen3-30B-A3B-Instruct-2507", "n_prompts": [1, 8], "n_samples": [1, 8], "prompt_len": 32000, "prompt_logprobs": [0, 1], "prompt_reuse": ["same_prompt", "unique_prompts"], "rank": 16, "repeats": 1, "sampling_session_id": "e02f213e-5534-413a-bfb2-67d16e018253", "save_weights_and_get_sampling_client_s": 14.9925129909534, "tokenizer_vocab_size": 151643, "ts": "2026-01-26T12:57:59+00:00", "unique_batches": true}
{"case_idx": 1, "kind": "case", "n_prompts": 1, "n_samples": 1, "poll_s": 0.2, "prompt_logprobs": 0, "prompt_reuse": "same_prompt", "repeat": 0, "topk_prompt_logprobs": 0, "ts": "2026-01-26T12:57:59+00:00"}
{"batch_wall_s": 48.80361754097976, "case_idx": 1, "client_total_s": 48.803215709049255, "error": null, "gen_max_tokens": 256, "kind": "request", "n_prompts": 1, "n_sampl
@yiwenlu66
yiwenlu66 / coalesce0.jsonl
Created January 26, 2026 12:42
issue #129: Qwen3-4B LoRA /asample sweep (coalesce0 vs coalesce1) pl=32000 mt=256
{"base_url": "http://localhost:8000", "create_training_client_s": 12.569012865889817, "filler_id": 264, "gen_max_tokens": 256, "git_sha": "6bbdb94175ac7ccd6675af3a3baec4f80c3392ff", "kind": "meta", "label": "coalesce0", "model": "Qwen/Qwen3-4B-Instruct-2507", "n_prompts": [1, 2, 4, 8], "n_samples": [1, 2, 4, 8], "prompt_len": 32000, "prompt_logprobs": [0, 1], "prompt_reuse": ["same_prompt", "unique_prompts"], "rank": 16, "repeats": 1, "sampling_session_id": "60ea6c1b-8761-4dd6-bde3-9dd78f44ca2a", "save_weights_and_get_sampling_client_s": 77.64279290300328, "tokenizer_vocab_size": 151643, "ts": "2026-01-26T11:33:42+00:00", "unique_batches": true}
{"case_idx": 1, "kind": "case", "n_prompts": 1, "n_samples": 1, "poll_s": 0.2, "prompt_logprobs": 0, "prompt_reuse": "same_prompt", "repeat": 0, "topk_prompt_logprobs": 0, "ts": "2026-01-26T11:33:42+00:00"}
{"batch_wall_s": 12.675236565992236, "case_idx": 1, "client_total_s": 12.674761680071242, "error": null, "gen_max_tokens": 256, "kind": "request", "n_prompts": 1,
@yiwenlu66
yiwenlu66 / whisper-dictate
Last active December 3, 2025 16:21
Whisper dictation: F2 to transcribe, F3 to transcribe + cleanup with Ollama (Qwen 2.5). ~160 lines, GPU-accelerated.
#!/usr/bin/env python3
"""Whisper dictation: F2 to transcribe, F3 to transcribe + cleanup with Ollama."""
import json
import re
import subprocess
import threading
import time
import urllib.request
import numpy as np
@yiwenlu66
yiwenlu66 / queue_gpu.py
Created August 4, 2017 05:03
A simple script to run a command as soon as a GPU is idle.
import subprocess
import time
import re
import sys
while True:
out = subprocess.check_output('nvidia-smi')
usage = int(re.search(b'\d*MiB /', out).group(0).split(b'M')[0])
if usage < 1000:
subprocess.Popen(sys.argv[1:])
@yiwenlu66
yiwenlu66 / bmarks.py
Last active March 28, 2016 02:53
Convert DJVU outline to PDF metadata
#!/usr/bin/env python3
import sys
import sexpdata
def walk_bmarks(bmarks, level):
output = ''
wroteTitle = False
for j in bmarks:
@yiwenlu66
yiwenlu66 / udpbroadcast.py
Last active December 20, 2022 17:56
udp broadcast with asyncio
import asyncio
import socket
from string import ascii_letters
import random
class BroadcastProtocol:
def __init__(self, loop):
self.loop = loop
@yiwenlu66
yiwenlu66 / ne2x-sign.py
Created August 2, 2015 02:08
NE2X 每日任务脚本
import requests
from bs4 import BeautifulSoup
# Fill in your account here
EMAIL = ""
PASSWD = ""
session = requests.Session()
main_url = "http://ne2x.com/"
main = session.get(main_url)
@yiwenlu66
yiwenlu66 / mczip
Created April 24, 2015 14:08
Multi-charset zip
# From http://www.robberphex.com/2013/05/141
# -*- coding: utf-8 -*-
import os
import sys
import zipfile
from optparse import OptionParser
def listZip(zipf):
print "Archive: %s" %zipf