freesolo-flash-dev 0.2.42__tar.gz → 0.2.44__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/Dockerfile.worker +6 -1
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/PKG-INFO +1 -1
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/cli/commands.py +21 -1
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/engine/worker/__init__.py +10 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/engine/worker/hf.py +41 -112
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/engine/worker/kernel_warmup.py +18 -1
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/engine/worker/perf/__init__.py +135 -1
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/engine/worker/sft.py +16 -6
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/providers/_worker.py +9 -6
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/pyproject.toml +2 -2
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_checkpoints.py +59 -170
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_cli_commands.py +34 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_flash_worker.py +1 -1
- freesolo_flash_dev-0.2.44/tests/test_sft_example_selection.py +36 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_worker_stack.py +225 -6
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/.dockerignore +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/.env.example +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/.github/workflows/auto-rebake.yml +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/.github/workflows/bake-kernel-cache.yml +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/.github/workflows/ci.yml +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/.github/workflows/main-source-guard.yml +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/.github/workflows/notify-tests-repo.yml +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/.github/workflows/publish-dev.yml +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/.github/workflows/publish-image.yml +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/.github/workflows/publish.yml +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/.github/workflows/version-parity.yml +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/.github/workflows/worker-image.yml +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/.gitignore +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/Dockerfile +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/LICENSE +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/README.md +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/build/kernel_cache/.gitignore +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/build/kernel_cache/.keep +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/docker/Dockerfile.kernelcache +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/docker/Dockerfile.kernelcache.relayer +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/docker/bake_kernel_cache.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/docker/bake_pod_entry.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/docker/kernel_fingerprint.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/docker/make_rp_handler.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/docs/cli-style/README.md +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/docs/cli-style/env-setup-survey-dark.png +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/docs/cli-style/env-setup-survey-light.png +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/docs/cli-style/generate.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/docs/cli-style/index.html +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/docs/cli-style/preview.png +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/docs/cli-style/themed-errors.png +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/docs/cli-style/train-config-error-after.png +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/docs/cli-style/train-config-error-before.png +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/docs/kernel-cache.md +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/__init__.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/_channel.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/_fileio.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/_logging.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/_update_check.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/adapter_artifacts.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/catalog.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/cli/__init__.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/cli/__main__.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/cli/_tty.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/cli/envpush.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/cli/render.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/cli/training_doc.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/client/__init__.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/client/config.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/client/http.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/client/runtime_secrets.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/client/specs.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/cost/__init__.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/cost/analytical.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/cost/facts.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/cost/spec.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/cost/types.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/engine/__init__.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/engine/accounting.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/engine/chalk_kernels.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/engine/multiturn_rollout.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/engine/recipe.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/engine/vram.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/engine/worker/__main__.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/engine/worker/_pkg.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/engine/worker/adapter.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/engine/worker/decoding.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/engine/worker/finalize.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/engine/worker/gpu_setup.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/engine/worker/grpo.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/engine/worker/heartbeat.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/engine/worker/lora.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/engine/worker/packing.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/engine/worker/perf/attn.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/engine/worker/perf/diagnostics.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/engine/worker/perf/lifecycle.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/engine/worker/perf/liger.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/engine/worker/perf/loraplus.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/engine/worker/perf/memory.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/engine/worker/rl.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/engine/worker/wandb_log.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/envs/__init__.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/envs/adapter.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/envs/archive_policy.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/envs/base.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/envs/loader.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/envs/pull.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/envs/registry.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/lora_rank.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/providers/__init__.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/providers/_auth.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/providers/_hf_artifacts.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/providers/_hf_retry.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/providers/_http.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/providers/_instance.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/providers/_instance_bootstrap.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/providers/_instance_poll.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/providers/_instance_provider.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/providers/_poll.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/providers/allocator.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/providers/base.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/providers/lambdalabs/__init__.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/providers/lambdalabs/api.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/providers/lambdalabs/auth.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/providers/lambdalabs/gpus.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/providers/lambdalabs/jobs/__init__.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/providers/lambdalabs/jobs/builders.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/providers/lambdalabs/preflight.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/providers/lambdalabs/pricing.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/providers/preflight.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/providers/realized.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/providers/runpod/__init__.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/providers/runpod/api.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/providers/runpod/auth.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/providers/runpod/cost.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/providers/runpod/gpus.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/providers/runpod/jobs.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/providers/runpod/keys.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/providers/runpod/preflight.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/providers/runpod/preload.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/providers/runpod/pricing.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/providers/runpod/slots.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/providers/runpod/train/__init__.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/providers/runpod/train/deps.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/providers/runpod/train/endpoints.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/providers/vast/__init__.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/providers/vast/api.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/providers/vast/auth.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/providers/vast/jobs/__init__.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/providers/vast/jobs/builders.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/providers/vast/preflight.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/providers/vast/pricing.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/py.typed +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/runner/__init__.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/runner/checkpoints.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/runner/deploy.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/runner/lifecycle.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/schema/__init__.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/schema/fields.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/serve/__init__.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/serve/deploy.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/serve/export.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/serve/pricing.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/server/__init__.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/server/__main__.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/server/_deps.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/server/_internal_client.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/server/_locks.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/server/_runtime.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/server/app.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/server/auth.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/server/billing.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/server/billing_retry.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/server/checkpoints.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/server/db.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/server/environment_registry.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/server/envs.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/server/reconcile.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/server/routes/__init__.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/server/routes/envs.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/server/routes/meta.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/server/routes/runs.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/server/routes/serving.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/server/run_registry.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/spec.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/infisical-entrypoint.sh +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/scripts/build_dev_dist.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/__init__.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/_helpers/__init__.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/_helpers/runner.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/_helpers/specs.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/_helpers/vast.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/conftest.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/fixtures/math_eval.jsonl +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/fixtures/math_train.jsonl +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/live/__init__.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/live/conftest.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/live/test_lambda_live.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/live/test_runpod_live.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/live/test_vast_live.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_agent_flash_cli_contract.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_algorithms.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_allocator.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_b200_rollout_opt.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_backend_jobspec_contract.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_billing_retry.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_cancel_remote.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_catalog_consistency.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_chalk_kernels.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_charge_pricing.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_cli_errors.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_cli_estimate.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_cli_help.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_cli_managed.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_cli_render_theme.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_client.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_client_server_integration.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_config_overrides.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_cost_analytical.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_cost_equation.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_cost_estimate.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_cost_hardware.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_cost_models.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_cost_rewards.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_dev_channel.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_disk_gb.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_endpoint_name.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_env_cache_evict.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_env_delete.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_env_download.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_env_download_api.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_env_no_install.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_env_publish.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_env_pull.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_env_pull_managed_control_plane.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_env_push.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_env_rate_limit_resolve.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_envs_coverage.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_export.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_flash_mvp.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_flashinfer_cache_dirs.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_github_urlopen_retry.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_gpus.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_grpo_mask_aware.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_grpo_params.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_grpo_sleep_gate.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_health_liveness.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_idle_endpoint_reaper.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_internal_client.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_jobs.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_kernel_cache.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_kernel_fingerprint.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_kv_util.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_lambda_runner.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_logging.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_login_perms.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_lora_rank_preflight.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_managed_hf_repo.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_metrics_schema_agent_contract.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_mig_guard.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_multiturn_rollout.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_oom_escalate_gpu.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_open_model_policy.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_orchestrator_flash.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_packing.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_poll_helpers.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_preflight.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_provider_routing.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_provider_teardown_robustness.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_providers_symmetry.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_realized_cost.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_resolve_params_b.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_resume_on_retry.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_runmgmt.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_runpod_api_delete.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_runpod_key_fingerprint.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_runpod_key_waterfall.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_runpod_slots.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_serve.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_server_api.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_server_billing.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_server_db.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_serving_contract.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_sft_gc_off.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_spec_and_validation.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_thinking_config.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_train_context_preflight.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_update_check.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_vast_api.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_vast_offers.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_vast_runner.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_verifiers.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_version.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_vl_warmstart_adapter_keys.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_vl_warmstart_recombine.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_vl_weight_sync.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_wandb_naming.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_warmstart_cross_repo.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_weight_cache.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_worker_dryrun.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_worker_hardexit.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_worker_image.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_worker_init_heartbeat.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/tests/test_worker_thinking.py +0 -0
- {freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/uv.lock +0 -0
|
@@ -69,7 +69,12 @@ RUN pip install --no-cache-dir \
|
|
|
69
69
|
# miscomputed with Triton>=3.4 (fla #640) — the fix is fla's TILELANG backend (correct there), so
|
|
70
70
|
# we bake the pinned tilelang==0.1.11 + apache-tvm-ffi==0.1.11 (0.1.12 double-registers TVM-FFI ->
|
|
71
71
|
# `import tilelang` aborts) and KEEP fla on every arch; flash.engine.worker._ensure_fla_fastpath_on_hopper
|
|
72
|
-
# ensures the tilelang backend is live on sm90 before any model import.
|
|
72
|
+
# ensures the tilelang backend is live on sm90 before any model import. The INVERSE holds on
|
|
73
|
+
# B200/sm100: THERE the tilelang chunk_bwd_dqkwg miscomputes gradients while the Triton path is
|
|
74
|
+
# correct — and the pinned fla default-enables tilelang wherever it imports (i.e. everywhere,
|
|
75
|
+
# since it is baked here for Hopper), so the worker opts sm100 out via FLA_TILELANG=0
|
|
76
|
+
# (engine.worker.perf._force_fla_triton_gdn_on_sm100; upstream default-gates tilelang to
|
|
77
|
+
# Hopper-only since fla #975). Validated win vs the old
|
|
73
78
|
# pure-PyTorch fallback (H100 SXM, Qwen3.5 hidden-2560 LoRA): seq4096 4.2x faster / 1.6x less mem,
|
|
74
79
|
# seq16384 12.6x / 1.9x, loss matches to 1.8e-4. fla is from git: the PyPI wheel is a broken stub
|
|
75
80
|
# (no fla.modules). The git URL is PINNED to a commit (not the moving default branch) for
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: freesolo-flash-dev
|
|
3
|
-
Version: 0.2.
|
|
3
|
+
Version: 0.2.44
|
|
4
4
|
Summary: Flash — managed LoRA post-training (SFT/GRPO) for Freesolo environments, driven by the `flash` CLI
|
|
5
5
|
Project-URL: Homepage, https://github.com/freesolo-co/flash
|
|
6
6
|
Project-URL: Repository, https://github.com/freesolo-co/flash
|
|
@@ -783,12 +783,32 @@ def cmd_runs(args) -> int:
|
|
|
783
783
|
|
|
784
784
|
|
|
785
785
|
def cmd_cancel(args) -> int:
|
|
786
|
-
|
|
786
|
+
client = client_from_config()
|
|
787
|
+
status = client.cancel_run(args.run_id)
|
|
787
788
|
payload = {"run_id": args.run_id, "state": status["state"]}
|
|
789
|
+
# A cancelled run is not necessarily worthless: every completed save interval already streamed
|
|
790
|
+
# a deployable checkpoint, even though the run shows adapter_ref=null / cost=0. Surface the
|
|
791
|
+
# surviving steps here so the run isn't discarded unseen. Best-effort: cancel never fails on it.
|
|
792
|
+
checkpoints: list[dict] = []
|
|
793
|
+
if payload["state"] == "cancelled":
|
|
794
|
+
try:
|
|
795
|
+
checkpoints = client.checkpoints(args.run_id)
|
|
796
|
+
except Exception:
|
|
797
|
+
checkpoints = []
|
|
788
798
|
if render.styled():
|
|
789
799
|
print(render.cancelled(payload))
|
|
790
800
|
else:
|
|
791
801
|
print(json.dumps(payload, indent=2))
|
|
802
|
+
if checkpoints:
|
|
803
|
+
top = max(c["step"] for c in checkpoints)
|
|
804
|
+
# stderr in the plain path so the machine-readable stdout JSON stays untouched.
|
|
805
|
+
out = sys.stdout if render.styled() else sys.stderr
|
|
806
|
+
msg = (
|
|
807
|
+
f"{len(checkpoints)} deployable checkpoint(s) survive this cancel — list with "
|
|
808
|
+
f"`flash checkpoints {args.run_id}`, deploy one with "
|
|
809
|
+
f"`flash deploy {args.run_id}/step-{top}`."
|
|
810
|
+
)
|
|
811
|
+
print(render.note(msg) if render.styled() else msg, file=out)
|
|
792
812
|
return 0
|
|
793
813
|
|
|
794
814
|
|
|
@@ -100,6 +100,7 @@ from flash.engine.worker.perf import (
|
|
|
100
100
|
_estimate_params,
|
|
101
101
|
_flash_attn_3_available,
|
|
102
102
|
_flash_attn_available,
|
|
103
|
+
_force_fla_triton_gdn_on_sm100,
|
|
103
104
|
_GpuPeakSampler,
|
|
104
105
|
_liger_default_for_model,
|
|
105
106
|
_memory_mode,
|
|
@@ -108,6 +109,7 @@ from flash.engine.worker.perf import (
|
|
|
108
109
|
_peak_gpu_gb,
|
|
109
110
|
_remove_fla_from_disk,
|
|
110
111
|
_reset_peak_gpu,
|
|
112
|
+
_restrict_fla_gdn_autotune_on_blackwell,
|
|
111
113
|
_sdpa_cudnn_ctx,
|
|
112
114
|
free_gpu,
|
|
113
115
|
fused_optim_name,
|
|
@@ -265,9 +267,15 @@ def main():
|
|
|
265
267
|
raise RetriableInfraError(
|
|
266
268
|
f"DONE present but metrics.json unreadable after retries (transient HF): {last_err}"
|
|
267
269
|
)
|
|
270
|
+
# BEFORE any model import / fla dispatch: on sm100 the baked tilelang GDN backend
|
|
271
|
+
# computes wrong gradients — opt out so fla uses its (correct-there) Triton path.
|
|
272
|
+
_force_fla_triton_gdn_on_sm100()
|
|
268
273
|
_ensure_fla_fastpath_on_hopper()
|
|
269
274
|
# Must run AFTER fla fast path (may reinstall tilelang) and BEFORE model/vLLM import.
|
|
270
275
|
_neutralize_tilelang_cudart_stub()
|
|
276
|
+
# AFTER the fla fast path (which may (re)install fla), BEFORE any model import / GDN
|
|
277
|
+
# launch: restrict fla's Blackwell GDN bwd autotune to grad-correct configs (fla #913).
|
|
278
|
+
_restrict_fla_gdn_autotune_on_blackwell()
|
|
271
279
|
heartbeat("boot", gpu=gpu_diagnostics(include_torch=False))
|
|
272
280
|
finalize_alloc_conf_for_sleep()
|
|
273
281
|
load_mega_cache()
|
|
@@ -344,6 +352,7 @@ __all__ = [
|
|
|
344
352
|
"_finalize",
|
|
345
353
|
"_flash_attn_3_available",
|
|
346
354
|
"_flash_attn_available",
|
|
355
|
+
"_force_fla_triton_gdn_on_sm100",
|
|
347
356
|
"_grpo_is_no_op_failure",
|
|
348
357
|
"_grpo_resume_already_complete",
|
|
349
358
|
"_hf_upload",
|
|
@@ -359,6 +368,7 @@ __all__ = [
|
|
|
359
368
|
"_remove_fla_from_disk",
|
|
360
369
|
"_reset_peak_gpu",
|
|
361
370
|
"_resolve_adapter_ref",
|
|
371
|
+
"_restrict_fla_gdn_autotune_on_blackwell",
|
|
362
372
|
"_sdpa_cudnn_ctx",
|
|
363
373
|
"assert_adapter_delta_nonzero",
|
|
364
374
|
"assert_adapter_load_clean",
|
|
@@ -310,11 +310,13 @@ def publish_deployable_checkpoint(
|
|
|
310
310
|
return None
|
|
311
311
|
|
|
312
312
|
|
|
313
|
-
#
|
|
314
|
-
_CKPT_FLUSH_TIMEOUT_S = 300.0
|
|
315
|
-
# Retry/backoff for the lock-timeout fallback publish (rides out a transient concurrent-commit 409).
|
|
313
|
+
# Retry/backoff for the deployable-adapter publish (rides out a transient concurrent-commit 409).
|
|
316
314
|
_CKPT_FLUSH_RETRIES = 3
|
|
317
315
|
_CKPT_FLUSH_BACKOFF_S = 1.0
|
|
316
|
+
# Retry/backoff for each synchronous checkpoint upload. `on_save` BLOCKS the training loop on the
|
|
317
|
+
# upload, so a transient HF error is retried until the step lands rather than costing the step.
|
|
318
|
+
_CKPT_UPLOAD_RETRIES = 3
|
|
319
|
+
_CKPT_UPLOAD_BACKOFF_S = 5.0
|
|
318
320
|
|
|
319
321
|
|
|
320
322
|
def _latest_checkpoint_dir(output_dir: str) -> tuple[int, str] | None:
|
|
@@ -368,72 +370,14 @@ def _prune_stale_resume_checkpoints(keep_step: int) -> None:
|
|
|
368
370
|
api.delete_folder(path_in_repo=folder, repo_id=_w.HF_REPO, repo_type="dataset")
|
|
369
371
|
|
|
370
372
|
|
|
371
|
-
class _UploadPump:
|
|
372
|
-
"""Coalescing single-slot upload queue: at most one upload in flight, at most one queued.
|
|
373
|
-
|
|
374
|
-
ONE lock guards two fields — ``uploading`` and ``queued`` (newest wins). Every producer path
|
|
375
|
-
is enqueue-then-pump and the upload thread's finally is done()-then-pump, so a save that
|
|
376
|
-
lands while the in-flight upload is draining can never be lost (no check-then-set window
|
|
377
|
-
between separate locks).
|
|
378
|
-
"""
|
|
379
|
-
|
|
380
|
-
def __init__(self, start_upload) -> None:
|
|
381
|
-
self._cond = threading.Condition()
|
|
382
|
-
self._start_upload = start_upload # (step, ckpt_dir) -> spawns thread; must call done()
|
|
383
|
-
self.uploading = False
|
|
384
|
-
self.queued: tuple[int, str] | None = None
|
|
385
|
-
|
|
386
|
-
def enqueue(self, step: int, ckpt_dir: str) -> None:
|
|
387
|
-
"""Queue `step` (replacing any older queued step) and start it if idle."""
|
|
388
|
-
with self._cond:
|
|
389
|
-
busy = self.uploading
|
|
390
|
-
self.queued = (step, ckpt_dir)
|
|
391
|
-
if busy:
|
|
392
|
-
print(
|
|
393
|
-
f"[ckpt] upload busy; queued step {step} (uploads when the in-flight one finishes)"
|
|
394
|
-
)
|
|
395
|
-
self.pump()
|
|
396
|
-
|
|
397
|
-
def pump(self) -> None:
|
|
398
|
-
"""Atomically start the queued upload iff nothing is in flight."""
|
|
399
|
-
with self._cond:
|
|
400
|
-
if self.uploading or self.queued is None:
|
|
401
|
-
return
|
|
402
|
-
step, ckpt_dir = self.queued
|
|
403
|
-
self.queued = None
|
|
404
|
-
gone = not os.path.isdir(ckpt_dir)
|
|
405
|
-
if not gone:
|
|
406
|
-
self.uploading = True
|
|
407
|
-
if gone: # pruned by the trainer's save_total_limit meanwhile
|
|
408
|
-
print(f"[ckpt] queued step {step} checkpoint dir is gone; dropping")
|
|
409
|
-
return
|
|
410
|
-
self._start_upload(step, ckpt_dir)
|
|
411
|
-
|
|
412
|
-
def done(self) -> None:
|
|
413
|
-
"""Mark the in-flight upload finished, then pump any queued step."""
|
|
414
|
-
with self._cond:
|
|
415
|
-
self.uploading = False
|
|
416
|
-
self._cond.notify_all()
|
|
417
|
-
self.pump()
|
|
418
|
-
|
|
419
|
-
def take_queued(self) -> tuple[int, str] | None:
|
|
420
|
-
"""Remove and return the queued step, if any (for a synchronous train-end flush)."""
|
|
421
|
-
with self._cond:
|
|
422
|
-
queued, self.queued = self.queued, None
|
|
423
|
-
return queued
|
|
424
|
-
|
|
425
|
-
def wait_idle(self, timeout: float) -> bool:
|
|
426
|
-
"""Wait up to `timeout` seconds for the in-flight upload (if any) to finish."""
|
|
427
|
-
with self._cond:
|
|
428
|
-
return self._cond.wait_for(lambda: not self.uploading, timeout)
|
|
429
|
-
|
|
430
|
-
|
|
431
373
|
def make_checkpoint_upload_callback():
|
|
432
374
|
"""Return a TrainerCallback that streams each save to HF and publishes deployable per-step adapters.
|
|
433
375
|
|
|
434
|
-
Uploads
|
|
435
|
-
|
|
436
|
-
|
|
376
|
+
Uploads are SYNCHRONOUS: on_save blocks the training loop until the checkpoint is durably on
|
|
377
|
+
HF. A save therefore never returns while its upload is still running, so there is never a
|
|
378
|
+
second upload in flight when the next save fires — the "upload busy" contention (and the
|
|
379
|
+
coalescing/dropping it used to cause) cannot happen by construction. Every `save_every` step is
|
|
380
|
+
guaranteed to upload, retrying transient HF errors instead of skipping.
|
|
437
381
|
"""
|
|
438
382
|
from transformers import TrainerCallback
|
|
439
383
|
|
|
@@ -491,72 +435,57 @@ def make_checkpoint_upload_callback():
|
|
|
491
435
|
_prune_stale_resume_checkpoints(step)
|
|
492
436
|
_w.heartbeat("checkpoint_uploaded", step=step)
|
|
493
437
|
|
|
494
|
-
|
|
495
|
-
"""Upload `step` in a background thread; the pump is marked done (and re-pumped) after."""
|
|
438
|
+
uploaded_steps: set[int] = set()
|
|
496
439
|
|
|
497
|
-
|
|
440
|
+
def _upload_with_retries(step: int, ckpt_dir: str) -> bool:
|
|
441
|
+
"""Run the full upload for `step`, retrying transient failures; True once it lands."""
|
|
442
|
+
for attempt in range(_CKPT_UPLOAD_RETRIES):
|
|
498
443
|
try:
|
|
499
444
|
_upload_once(step, ckpt_dir)
|
|
445
|
+
uploaded_steps.add(step)
|
|
446
|
+
return True
|
|
500
447
|
except Exception as e:
|
|
501
|
-
|
|
502
|
-
|
|
503
|
-
|
|
504
|
-
|
|
505
|
-
|
|
506
|
-
|
|
507
|
-
|
|
508
|
-
|
|
509
|
-
|
|
510
|
-
|
|
511
|
-
|
|
512
|
-
|
|
448
|
+
if attempt + 1 < _CKPT_UPLOAD_RETRIES:
|
|
449
|
+
print(
|
|
450
|
+
f"[ckpt] step {step} upload retry {attempt + 1}/{_CKPT_UPLOAD_RETRIES}: {e}"
|
|
451
|
+
)
|
|
452
|
+
time.sleep(_CKPT_UPLOAD_BACKOFF_S * (attempt + 1))
|
|
453
|
+
else:
|
|
454
|
+
print(
|
|
455
|
+
f"[ckpt] step {step} upload FAILED after {_CKPT_UPLOAD_RETRIES} attempts: {e}"
|
|
456
|
+
)
|
|
457
|
+
with contextlib.suppress(Exception):
|
|
458
|
+
_w.heartbeat("checkpoint_upload_failed", step=step)
|
|
459
|
+
return False
|
|
513
460
|
|
|
514
461
|
class _CheckpointUpload(TrainerCallback):
|
|
515
462
|
def on_save(self, args, state, control, **kwargs):
|
|
463
|
+
# SYNCHRONOUS on the training thread: the trainer blocks here until this checkpoint is
|
|
464
|
+
# uploaded. `save_total_limit=1` rotation (which runs earlier, inside this same save's
|
|
465
|
+
# `_save_checkpoint`) deletes the PREVIOUS checkpoint, never the current one — and the
|
|
466
|
+
# next save can't begin until we return — so the dir is stable for the whole upload and
|
|
467
|
+
# no snapshot/queue is needed. Because the upload finishes before the save returns,
|
|
468
|
+
# there is never a concurrent upload for a later save to be "busy" against.
|
|
516
469
|
if not _w.HF_REPO:
|
|
517
470
|
return
|
|
518
471
|
step = int(state.global_step)
|
|
519
472
|
ckpt_dir = os.path.join(args.output_dir, f"checkpoint-{step}")
|
|
520
473
|
if not os.path.isdir(ckpt_dir):
|
|
521
474
|
return
|
|
522
|
-
|
|
475
|
+
_upload_with_retries(step, ckpt_dir)
|
|
523
476
|
|
|
524
477
|
def on_train_end(self, args, state, control, **kwargs):
|
|
525
|
-
#
|
|
478
|
+
# Safety net for a final checkpoint the trainer wrote without an on_save (e.g. a
|
|
479
|
+
# load_best_model_at_end / end-of-training save). Synchronous on_save already uploaded
|
|
480
|
+
# every step it saw, so this only publishes an as-yet-unuploaded latest step.
|
|
526
481
|
if not _w.HF_REPO:
|
|
527
482
|
return
|
|
528
483
|
latest = _latest_checkpoint_dir(args.output_dir)
|
|
529
484
|
if latest is None:
|
|
530
485
|
return
|
|
531
486
|
step, ckpt_dir = latest
|
|
532
|
-
|
|
533
|
-
|
|
534
|
-
|
|
535
|
-
idle = pump.wait_idle(_CKPT_FLUSH_TIMEOUT_S)
|
|
536
|
-
if queued is not None and os.path.isdir(queued[1]):
|
|
537
|
-
q_step, q_dir = queued
|
|
538
|
-
if idle:
|
|
539
|
-
try:
|
|
540
|
-
_upload_once(q_step, q_dir)
|
|
541
|
-
except Exception as e:
|
|
542
|
-
print("ckpt upload warn:", e)
|
|
543
|
-
else:
|
|
544
|
-
# Another upload is still pruning latest-only resume checkpoints. Publish only
|
|
545
|
-
# the durable per-step adapter here so concurrent prune passes cannot delete a
|
|
546
|
-
# newer resume checkpoint while it is being flushed.
|
|
547
|
-
try:
|
|
548
|
-
_publish_deployable_recombined(q_dir, q_step, with_retry=True)
|
|
549
|
-
except Exception as e:
|
|
550
|
-
print("ckpt deployable flush warn:", e)
|
|
551
|
-
if q_step == step:
|
|
552
|
-
return # the queued flush already published the final deployable
|
|
553
|
-
if idle:
|
|
554
|
-
_publish_deployable_recombined(ckpt_dir, step)
|
|
555
|
-
else:
|
|
556
|
-
print(
|
|
557
|
-
f"[ckpt] upload still in flight after {_CKPT_FLUSH_TIMEOUT_S:.0f}s; publishing "
|
|
558
|
-
f"final deployable (step {step}) alongside it"
|
|
559
|
-
)
|
|
560
|
-
_publish_deployable_recombined(ckpt_dir, step, with_retry=True)
|
|
487
|
+
if step in uploaded_steps:
|
|
488
|
+
return
|
|
489
|
+
_upload_with_retries(step, ckpt_dir)
|
|
561
490
|
|
|
562
491
|
return _CheckpointUpload()
|
{freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/engine/worker/kernel_warmup.py
RENAMED
|
@@ -77,7 +77,9 @@ def _require_gpu():
|
|
|
77
77
|
if not torch.cuda.is_available():
|
|
78
78
|
_log("no CUDA device visible — kernel warmup must run on a GPU builder; nothing baked")
|
|
79
79
|
return None
|
|
80
|
-
_log(
|
|
80
|
+
_log(
|
|
81
|
+
f"GPU: {torch.cuda.get_device_name(0)} ({_torch_sm(torch)}), torch {torch.__version__}"
|
|
82
|
+
)
|
|
81
83
|
return torch
|
|
82
84
|
except Exception as e:
|
|
83
85
|
_log(f"torch unavailable ({e}); cannot warm kernels")
|
|
@@ -128,6 +130,13 @@ def warm_flash_attn(torch) -> bool:
|
|
|
128
130
|
def warm_fla_gdn(torch) -> bool:
|
|
129
131
|
"""Compile flash-linear-attention's Gated-DeltaNet chunk kernels (Qwen3.5/3.6 hybrid path)."""
|
|
130
132
|
try:
|
|
133
|
+
# sm100: tilelang's GDN bwd miscomputes grads — warm the Triton path the worker will run.
|
|
134
|
+
try:
|
|
135
|
+
from flash.engine.worker.perf import _force_fla_triton_gdn_on_sm100
|
|
136
|
+
|
|
137
|
+
_force_fla_triton_gdn_on_sm100()
|
|
138
|
+
except Exception as e:
|
|
139
|
+
_log(f"sm100 fla tilelang opt-out skipped: {e}")
|
|
131
140
|
# fla #640: GDN chunk_bwd needs tilelang on Hopper; Triton path miscomputes/raises there.
|
|
132
141
|
try:
|
|
133
142
|
from flash.engine.worker.perf import _ensure_fla_fastpath_on_hopper
|
|
@@ -135,6 +144,14 @@ def warm_fla_gdn(torch) -> bool:
|
|
|
135
144
|
_ensure_fla_fastpath_on_hopper()
|
|
136
145
|
except Exception as e:
|
|
137
146
|
_log(f"hopper fla fast-path setup skipped: {e}")
|
|
147
|
+
# fla #913: on Blackwell, warm the SAME restricted autotune space the worker boot will
|
|
148
|
+
# run (grad-correct configs only) so the baked cache holds the config that actually runs.
|
|
149
|
+
try:
|
|
150
|
+
from flash.engine.worker.perf import _restrict_fla_gdn_autotune_on_blackwell
|
|
151
|
+
|
|
152
|
+
_restrict_fla_gdn_autotune_on_blackwell()
|
|
153
|
+
except Exception as e:
|
|
154
|
+
_log(f"blackwell fla autotune restriction skipped: {e}")
|
|
138
155
|
from fla.ops.gated_delta_rule import chunk_gated_delta_rule
|
|
139
156
|
|
|
140
157
|
b, h, t, d = 1, 4, 256, 64
|
{freesolo_flash_dev-0.2.42 → freesolo_flash_dev-0.2.44}/flash/engine/worker/perf/__init__.py
RENAMED
|
@@ -131,7 +131,7 @@ def _find_real_libcudart() -> str | None:
|
|
|
131
131
|
with open("/proc/self/maps") as f:
|
|
132
132
|
for line in f:
|
|
133
133
|
if base in line and "/" in line:
|
|
134
|
-
p = line[line.index("/"):].rstrip()
|
|
134
|
+
p = line[line.index("/") :].rstrip()
|
|
135
135
|
if os.path.basename(p).startswith(base) and os.path.exists(p):
|
|
136
136
|
return os.path.realpath(p)
|
|
137
137
|
except OSError:
|
|
@@ -208,6 +208,138 @@ def _neutralize_tilelang_cudart_stub() -> None:
|
|
|
208
208
|
print(f"[worker] libcudart stub neutralize failed: {e}", flush=True)
|
|
209
209
|
|
|
210
210
|
|
|
211
|
+
def _force_fla_triton_gdn_on_sm100() -> None:
|
|
212
|
+
"""Opt fla OUT of its tilelang GDN backend on B200 (sm100) via ``FLA_TILELANG=0``.
|
|
213
|
+
|
|
214
|
+
The worker image bakes tilelang for the HOPPER fast path (fla #640), but the pinned fla
|
|
215
|
+
default-enables its tilelang backend WHEREVER tilelang imports. On sm100, tilelang's
|
|
216
|
+
``chunk_bwd_dqkwg`` computes WRONG GRADIENTS — measured on a real B200 with this exact image
|
|
217
|
+
at the production Qwen3.5/3.6 GDN call shapes (H==HV after transformers' head repeat):
|
|
218
|
+
dq/dk rel-err ~0.72, dg ~1.28 vs the fp32 reference, deterministic, in bf16 AND fp32, while
|
|
219
|
+
the same shapes on H200 are correct to ~4e-3. This is the root cause of the B200 35B-A3B SFT
|
|
220
|
+
incident (grad_norm ~1e8 from the first logged step; loss flat at LR 2e-5/5e-5, collapse at
|
|
221
|
+
1e-4 — garbage gradient DIRECTIONS no LR can fix, while H200 trained healthily at 1e-4).
|
|
222
|
+
|
|
223
|
+
``FLA_TILELANG=0`` flips fla's dispatch to its Triton chunk_bwd_dqkwg — verified correct on
|
|
224
|
+
sm100 at the same shapes (~4e-3). Upstream has since stopped default-enabling tilelang
|
|
225
|
+
off-Hopper (fla #975 gates the default to sm90 + Triton>=3.4) and an explicit env opt-out
|
|
226
|
+
wins on every fla version, so this env set reproduces upstream's current gate on our pin and
|
|
227
|
+
stays a correct no-op across a future pin bump.
|
|
228
|
+
|
|
229
|
+
* ``setdefault``: an explicitly pre-set FLA_TILELANG (e.g. testing a fixed tilelang) wins.
|
|
230
|
+
* sm100 only: sm90 NEEDS tilelang (fla #640, the fast-path installer owns it); sm89/sm120
|
|
231
|
+
train healthily today under the pin's default and upstream's next-pin gate flips them to
|
|
232
|
+
Triton anyway — no evidence to justify changing them from here.
|
|
233
|
+
* Env is read live per-dispatch by fla, but set it at boot BEFORE any model import so no
|
|
234
|
+
kernel ever launches under the old default.
|
|
235
|
+
"""
|
|
236
|
+
try:
|
|
237
|
+
import torch
|
|
238
|
+
|
|
239
|
+
if not (torch.cuda.is_available() and torch.cuda.get_device_capability() == (10, 0)):
|
|
240
|
+
return
|
|
241
|
+
except Exception:
|
|
242
|
+
return
|
|
243
|
+
prior = os.environ.get("FLA_TILELANG")
|
|
244
|
+
if prior is not None:
|
|
245
|
+
print(
|
|
246
|
+
f"[blackwell] FLA_TILELANG={prior!r} pre-set; respecting it "
|
|
247
|
+
"(default here is 0 on sm100: tilelang chunk_bwd_dqkwg miscomputes grads)",
|
|
248
|
+
flush=True,
|
|
249
|
+
)
|
|
250
|
+
return
|
|
251
|
+
os.environ["FLA_TILELANG"] = "0"
|
|
252
|
+
print(
|
|
253
|
+
"[blackwell] sm100 (B200): FLA_TILELANG=0 -> fla GDN uses the Triton chunk_bwd_dqkwg "
|
|
254
|
+
"(tilelang backend computes wrong gradients on sm100; measured dq/dk ~0.72, dg ~1.28 "
|
|
255
|
+
"rel-err; upstream default-gates tilelang to Hopper since fla #975)",
|
|
256
|
+
flush=True,
|
|
257
|
+
)
|
|
258
|
+
|
|
259
|
+
|
|
260
|
+
def _restrict_fla_gdn_autotune_on_blackwell() -> None:
|
|
261
|
+
"""Restrict fla's GDN ``prepare_wy_repr_bwd_kernel`` autotune space on Blackwell (sm100/sm120).
|
|
262
|
+
|
|
263
|
+
Defense-in-depth for the Triton GDN backward path — the path sm100 defaults to once
|
|
264
|
+
``_force_fla_triton_gdn_on_sm100`` opts out of tilelang. Upstream reports that Blackwell can
|
|
265
|
+
select unstable Triton configs for this kernel during autotuning (fla #913) and restricted
|
|
266
|
+
the space to the B200-validated config (num_warps=2, num_stages=4) in fla #1000 (ac6c648) —
|
|
267
|
+
NEWER than the worker's pinned fla SHA — so apply the same restriction in-process at boot,
|
|
268
|
+
before any GDN kernel launch. (Not the 35B-A3B incident root cause — that was tilelang, see
|
|
269
|
+
above — but there is no reason to keep autotuning over configs upstream deemed unstable on
|
|
270
|
+
the exact card we train on.)
|
|
271
|
+
|
|
272
|
+
* No-op on non-Blackwell arches, when fla is absent (pure-PyTorch delta path), or when the
|
|
273
|
+
pinned fla already carries the upstream fix (filtering an already-restricted space).
|
|
274
|
+
* Fail-CLOSED like the Hopper fast path: if fla is present on Blackwell but the restriction
|
|
275
|
+
cannot be applied (autotuner layout changed — e.g. an unreviewed pin bump), physically
|
|
276
|
+
remove fla so transformers falls back to the pure-PyTorch delta rule. Slow-but-correct
|
|
277
|
+
beats a run that burns GPU-hours computing garbage gradients.
|
|
278
|
+
* sm120 is included to match upstream's IS_NVIDIA_BLACKWELL gate: 5090 smokes trained fine on
|
|
279
|
+
the unrestricted space, but that is autotune luck (the winning config varies per shape/run),
|
|
280
|
+
not evidence of safety.
|
|
281
|
+
"""
|
|
282
|
+
try:
|
|
283
|
+
import torch
|
|
284
|
+
|
|
285
|
+
if not (torch.cuda.is_available() and torch.cuda.get_device_capability()[0] in (10, 12)):
|
|
286
|
+
return
|
|
287
|
+
except Exception:
|
|
288
|
+
return
|
|
289
|
+
try:
|
|
290
|
+
import importlib.util
|
|
291
|
+
|
|
292
|
+
if importlib.util.find_spec("fla") is None:
|
|
293
|
+
return # no fla -> transformers already uses the pure-PyTorch delta path
|
|
294
|
+
except Exception:
|
|
295
|
+
return
|
|
296
|
+
|
|
297
|
+
def _fail_closed(reason: str) -> None:
|
|
298
|
+
_removed, _still = _remove_fla_from_disk()
|
|
299
|
+
print(
|
|
300
|
+
f"[blackwell] fla GDN autotune restriction FAILED ({reason}) -> DISABLING fla "
|
|
301
|
+
f"(removed {len(_removed)} copy(ies); still_importable={_still}); "
|
|
302
|
+
"pure-PyTorch delta fallback (fla #913: unrestricted autotune miscomputes grads)",
|
|
303
|
+
flush=True,
|
|
304
|
+
)
|
|
305
|
+
|
|
306
|
+
try:
|
|
307
|
+
from fla.ops.gated_delta_rule import wy_fast
|
|
308
|
+
|
|
309
|
+
tuner = getattr(wy_fast, "prepare_wy_repr_bwd_kernel", None)
|
|
310
|
+
for _ in range(8): # unwrap decorator layers (heuristics/cache) down to the Autotuner
|
|
311
|
+
if tuner is None or hasattr(tuner, "configs"):
|
|
312
|
+
break
|
|
313
|
+
tuner = getattr(tuner, "fn", None)
|
|
314
|
+
configs = getattr(tuner, "configs", None)
|
|
315
|
+
if not configs:
|
|
316
|
+
_fail_closed("prepare_wy_repr_bwd_kernel autotuner not found")
|
|
317
|
+
return
|
|
318
|
+
keep = [
|
|
319
|
+
c
|
|
320
|
+
for c in configs
|
|
321
|
+
if getattr(c, "num_warps", None) == 2 and getattr(c, "num_stages", None) == 4
|
|
322
|
+
]
|
|
323
|
+
if not keep:
|
|
324
|
+
_fail_closed("no B200-validated config (num_warps=2/num_stages=4) in autotune space")
|
|
325
|
+
return
|
|
326
|
+
if len(keep) == len(configs):
|
|
327
|
+
print(
|
|
328
|
+
"[blackwell] fla GDN autotune already restricted (pinned fla carries fla #1000)",
|
|
329
|
+
flush=True,
|
|
330
|
+
)
|
|
331
|
+
return
|
|
332
|
+
tuner.configs = keep
|
|
333
|
+
print(
|
|
334
|
+
f"[blackwell] fla GDN prepare_wy_repr_bwd autotune restricted {len(configs)} -> "
|
|
335
|
+
f"{len(keep)} config(s) (num_warps=2/num_stages=4; fla #913/#1000 grad miscompute)",
|
|
336
|
+
flush=True,
|
|
337
|
+
)
|
|
338
|
+
except Exception as e:
|
|
339
|
+
with contextlib.suppress(Exception):
|
|
340
|
+
_fail_closed(f"{type(e).__name__}: {e}")
|
|
341
|
+
|
|
342
|
+
|
|
211
343
|
def _ensure_fla_fastpath_on_hopper() -> None:
|
|
212
344
|
"""Enable fla's tilelang GDN backend on Hopper (sm90); no-op elsewhere.
|
|
213
345
|
|
|
@@ -334,6 +466,7 @@ __all__ = [
|
|
|
334
466
|
"_flash_attn_3_available",
|
|
335
467
|
"_flash_attn_available",
|
|
336
468
|
"_float_or_none",
|
|
469
|
+
"_force_fla_triton_gdn_on_sm100",
|
|
337
470
|
"_int_or_none",
|
|
338
471
|
"_liger_default_for_model",
|
|
339
472
|
"_memory_mode",
|
|
@@ -344,6 +477,7 @@ __all__ = [
|
|
|
344
477
|
"_query_nvidia_processes",
|
|
345
478
|
"_remove_fla_from_disk",
|
|
346
479
|
"_reset_peak_gpu",
|
|
480
|
+
"_restrict_fla_gdn_autotune_on_blackwell",
|
|
347
481
|
"_round_gb_from_mib",
|
|
348
482
|
"_sdpa_cudnn_ctx",
|
|
349
483
|
"free_gpu",
|
|
@@ -99,6 +99,21 @@ def _model_arch_dims(model_id: str) -> tuple[int, int]:
|
|
|
99
99
|
return c_hidden, c_layers
|
|
100
100
|
|
|
101
101
|
|
|
102
|
+
def select_sft_examples(train, max_examples, seed):
|
|
103
|
+
"""Pick the SFT sample: the first ``max_examples`` rows of the dataset (file order), shuffled.
|
|
104
|
+
|
|
105
|
+
The slice happens BEFORE the shuffle so ``max_examples`` is a deterministic prefix fence,
|
|
106
|
+
not a random subsample. A train.jsonl that carries fully-labeled SFT rows first and
|
|
107
|
+
prompt-only (empty-output) GRPO rows after can cap SFT to the labeled head — an empty
|
|
108
|
+
completion can never be shuffled into the SFT sample and teach the model to emit nothing.
|
|
109
|
+
"""
|
|
110
|
+
if max_examples > 0:
|
|
111
|
+
train = train[:max_examples]
|
|
112
|
+
rng = random.Random(seed)
|
|
113
|
+
rng.shuffle(train)
|
|
114
|
+
return train
|
|
115
|
+
|
|
116
|
+
|
|
102
117
|
def run_sft():
|
|
103
118
|
from datasets import Dataset
|
|
104
119
|
from transformers import AutoTokenizer
|
|
@@ -122,12 +137,7 @@ def run_sft():
|
|
|
122
137
|
val = getattr(_t, name, None) if _t else None
|
|
123
138
|
return val if val is not None else default
|
|
124
139
|
|
|
125
|
-
train = env.dataset()
|
|
126
|
-
rng = random.Random(_w.SEED)
|
|
127
|
-
rng.shuffle(train)
|
|
128
|
-
max_examples = int(_train_opt("max_examples", 0) or 0)
|
|
129
|
-
if max_examples > 0:
|
|
130
|
-
train = train[:max_examples]
|
|
140
|
+
train = select_sft_examples(env.dataset(), int(_train_opt("max_examples", 0) or 0), _w.SEED)
|
|
131
141
|
texts = []
|
|
132
142
|
multiturn_targets = 0
|
|
133
143
|
for ex in train:
|
|
@@ -41,7 +41,9 @@ WORKER_DEPS = [
|
|
|
41
41
|
"wandb>=0.17",
|
|
42
42
|
# fla from git: PyPI wheel is a broken stub missing fla.modules. SHA-pinned for reproducibility;
|
|
43
43
|
# keep in lockstep with Dockerfile.worker. fla kept on ALL arches — worker ensures tilelang
|
|
44
|
-
# backend on sm90 before model import (fla #640: chunk_bwd miscompute with Triton>=3.4 on Hopper)
|
|
44
|
+
# backend on sm90 before model import (fla #640: chunk_bwd miscompute with Triton>=3.4 on Hopper)
|
|
45
|
+
# and OPTS OUT of tilelang on sm100 (B200) where tilelang's chunk_bwd_dqkwg miscomputes grads
|
|
46
|
+
# (worker _force_fla_triton_gdn_on_sm100; upstream default-gates tilelang to Hopper since fla #975).
|
|
45
47
|
"flash-linear-attention @ git+https://github.com/fla-org/flash-linear-attention.git@f0e213dbd8b5fb90c3c7eca869ac1706d5377139",
|
|
46
48
|
# tilelang version-pinned in lockstep with Dockerfile.worker + perf.py runtime reinstall.
|
|
47
49
|
"tilelang==0.1.11",
|
|
@@ -110,13 +112,14 @@ def _effective_worker_env(spec=None) -> dict[str, str]:
|
|
|
110
112
|
# Chalk is published to PUBLIC PyPI on every version bump (chalk .github/workflows/publish.yml).
|
|
111
113
|
# Pin the exact PUBLIC version so worker + kernel-cache-bake pods install with NO GitHub auth — the
|
|
112
114
|
# chalk repo is INTERNAL, so a git+https default made installs fail wherever GITHUB_TOKEN is absent
|
|
113
|
-
# (bake pod, tokenless workers). freesolo-chalk 0.5.
|
|
114
|
-
#
|
|
115
|
-
#
|
|
116
|
-
DEFAULT_CHALK_VERSION
|
|
115
|
+
# (bake pod, tokenless workers). freesolo-chalk 0.5.3 = chalk dev->main sync #67 (adds the decode
|
|
116
|
+
# serving kernels rope + GDN gated-rmsnorm; GPU-A/B'd launch tuning: flce chunk_mult 16, rope
|
|
117
|
+
# num_warps=2, gdn_conv warps formula, lora fwd autotune candidate; OP_MEAS_OVERRIDE; flce
|
|
118
|
+
# chunk_mult tradeoff docs). Bump DEFAULT_CHALK_VERSION when the merged kernel surface moves.
|
|
119
|
+
DEFAULT_CHALK_VERSION = "0.5.3"
|
|
117
120
|
DEFAULT_CHALK_SPEC = f"freesolo-chalk=={DEFAULT_CHALK_VERSION}"
|
|
118
121
|
# Provenance only (kernel-cache fingerprint / traceability): the chalk commit this version was cut from.
|
|
119
|
-
LATEST_CHALK_MAIN_SHA = "
|
|
122
|
+
LATEST_CHALK_MAIN_SHA = "c63f0367e01795006bc0e91e2540ec85e740f19b"
|
|
120
123
|
|
|
121
124
|
|
|
122
125
|
def chalk_extra_pip(spec=None) -> list[str]:
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
[project]
|
|
2
2
|
name = "freesolo-flash-dev"
|
|
3
|
-
version = "0.2.
|
|
3
|
+
version = "0.2.44"
|
|
4
4
|
description = "Flash — managed LoRA post-training (SFT/GRPO) for Freesolo environments, driven by the `flash` CLI"
|
|
5
5
|
readme = "README.md"
|
|
6
6
|
# RunPod Flash supports Python 3.11-3.12 (not 3.13 yet).
|
|
@@ -106,7 +106,7 @@ artifacts = ["flash/py.typed"]
|
|
|
106
106
|
# auto-published by .github/workflows/publish-dev.yml: a push to `dev` whose version isn't yet on
|
|
107
107
|
# PyPI publishes it; pushes that don't change it find it already published and no-op. So cutting a
|
|
108
108
|
# dev-channel release = bump this (and [project].version) and merge to `dev`.
|
|
109
|
-
version = "0.2.
|
|
109
|
+
version = "0.2.44"
|
|
110
110
|
|
|
111
111
|
[tool.pytest.ini_options]
|
|
112
112
|
pythonpath = ["."]
|