training-and-export
Route questions about TF1 dense and sparse training, checkpointing, SavedModel export, inference, TensorBoard events, and legacy queue/distributed notes.
- License 许可
- Apache-2.0
- 最近更新
- 2026-09-03
- Stars
- ★ 351
- Forks
- 27
01 前言 Front Matter
- name
- training-and-export
- license
- Apache 2.0
- metadata
- { "disco-role": "operating" }
- description
- Route questions about TF1 dense and sparse training, checkpointing, SavedModel export, inference, TensorBoard events, and legacy queue/distributed notes.
- disable-model-invocation
- true
02 资源文件 6
- 参考文档references/cli-reference.md7.0 KB
- 参考文档references/model-overview.md5.8 KB
- 参考文档references/troubleshooting.md7.0 KB
- 参考文档references/workflows.md5.5 KB
- 脚本scripts/build_training_command.py30.3 KB
- 脚本scripts/read_tensorboard_events.py4.2 KB
03 SKILL.md 正文
Training and Export
Use this sub-skill when a user asks about:
- dense or sparse training
- checkpoint save/restore and SavedModel export
- local inference from checkpoints or exported models
- supported models, optimizers, losses, and data flags
- TensorBoard event reading
- legacy queue or distributed training variants
Read first
references/model-overview.md— model families, losses, optimizers, and export outputs.references/cli-reference.md— current flags, default modes, and README-era aliases.references/workflows.md— train/export/inference/TensorBoard recipes plus advanced notes.references/troubleshooting.md— TF1-only runtime, DuplicateFlagError, shape, export, and log issues.scripts/build_training_command.py— validates and normalizes dense/sparse commands.scripts/read_tensorboard_events.py— path-parameterized TensorBoard event inspection.
What this sub-skill covers
- Dense
tf.datatraining and sparse TFRecords training. - Checkpointing, SavedModel export, and checkpoint-based inference.
- Supported models, optimizers, losses, and data-layout flags.
- TensorBoard scalar/event reading.
- Legacy queue and distributed notes when the user explicitly asks for them.
Route elsewhere
- Dataset conversion, CSV/LIBSVM/TFRecords creation, and fixture generation belong to the data-preparation sub-skill.
- TensorFlow Serving clients, prediction requests, and HTTP/mobile clients belong to the serving-and-clients sub-skill.
- Cross-repo tuning, benchmark sweeps, or package installation are out of scope unless they are needed to answer a training/export question.
Fast routing rules
- If the question is about flag names or legacy README examples, open
references/cli-reference.mdfirst. - If the question is about model choices or loss/optimizer support, open
references/model-overview.mdfirst. - If the user wants a safe command, use
scripts/build_training_command.pyto normalize aliases and check combinations before hand-writing the command. - If the user wants to inspect TensorBoard output, use
scripts/read_tensorboard_events.pyagainst the event file or log directory. - If the user mentions TF2, missing
tf.contrib, orDuplicateFlagError, go straight toreferences/troubleshooting.md. - Keep dense and sparse trainers in separate processes; both register
tf.app.flagsat import time. - Dense uses
mode=train|savedmodel|inference; sparse usesmode=train|save_model|inference|inference_with_tfrecords.
Common answers this sub-skill can give
- Which dense or sparse mode to use.
- How to restore from checkpoint and export a SavedModel.
- Which model name fits a given feature layout.
- Which flag names are current versus README-era aliases.
- Why a TensorBoard log or SavedModel export failed.
04 同仓库更多 Skills
passnet-triton-opt
Make a single PassNet Triton kernel fast AND numerically faithful: performance model (when a replacement can win at all), block/grid/warp tuning, autotune policy, launch overhead, and per-op numeric recipes to pass the dtype baseline tolerances. Use when a pass matches and is correct but speedup below expected, or when correctness fails by small numeric margins.
passnet-solve
END-TO-END playbook for solving one PassNet sample: analyze the computation graphs, decide the optimization strategy (what to fuse, what to replace, what to leave alone), drive the iteration loop, and maximize the sample score. This is the ENTRY skill — invoke it first for any PassNet optimization task; it tells you when to use passnet-pattern-fusion, passnet-triton-opt and passnet-feedback.
passnet-skill
PassNet GPU kernel optimization via compiler passes. Design and implement Triton-based optimization passes, create pass files under ./pass_dir/, self-evaluate with pass_evaluator, and iterate to maximize GPU speedup.
passnet-pattern-fusion
Author PassNet pass files: write patterns that actually MATCH the FX graph, pick fusion regions (which ops to absorb into one Triton kernel), and structure multi-pass submissions with the mandatory shared-dispatch architecture. Use when creating or fixing pattern()/replacement_args()/replacement_func() files, when a pass "failed to match", or when deciding how to fuse multiple kernels/ops.
passnet-orchestrate
Round/batch planning and decision support for PassNet graph optimization. Use for multi-sample triage, worker allocation, eval-budget policy, and post-eval keep/revert decisions. For solving one concrete sample end to end, use passnet-solve as the entry skill; consult this skill only when you need broader planning or a specific decision gate.
passnet-feedback
Fast, deterministic feedback for PassNet work: pre-flight pattern/match verification WITHOUT burning a GPU evaluation, per-node bottleneck analysis of a sample's graphs, and eval-log parsing into per-variant status + estimated score + failure classification. Use BEFORE every GPU evaluation (check_pattern), at the START of a sample (analyze_graph), and AFTER every evaluation (parse_eval_log).