AGENT SKILL

discrete-transforms

Routes PyWavelets users through DWT, IDWT, multilevel transforms, SWT, MRA, coefficient packing, thresholding, padding, and fully separable transforms.

License 许可
MIT
最近更新
2026-09-03
Stars
★ 351
Forks
27

01 前言 Front Matter

name
discrete-transforms
license
MIT
metadata
{ "disco-role": "operating" }
description
Routes PyWavelets users through DWT, IDWT, multilevel transforms, SWT, MRA, coefficient packing, thresholding, padding, and fully separable transforms.
disable-model-invocation
true

02 资源文件 3

03 SKILL.md 正文

Discrete Transforms

Use this sub-skill for the core pywt transform stack: decimated DWT/IDWT, 2D and ND transforms, coefficient packing, stationary wavelets, multiresolution analysis, thresholding, signal-extension modes, padding, and fully separable transforms.

Route here when the task asks for

  • dwt, idwt, wavedec, waverec, dwt2, idwt2, wavedec2, waverec2
  • dwtn, idwtn, wavedecn, waverecn
  • swt, iswt, swt2, iswt2, swtn, iswtn
  • mra, mra2, mran, imra, imra2, imran
  • coeffs_to_array, array_to_coeffs, ravel_coeffs, unravel_coeffs, wavedecn_size, wavedecn_shapes
  • threshold, threshold_firm, pad, Modes.modes, dwt_coeff_len, dwt_max_level, dwtn_max_level
  • fswavedecn, fswaverecn, or FswavedecnResult

Route elsewhere when the task is about

  • wavelet catalogs, custom wavelets, wavefun, central_frequency, scale2frequency, or cwt: go to ../wavelets-and-cwt/SKILL.md
  • packet trees, node paths, packet reconstruction, or WaveletPacket*: go to ../wavelet-packets/SKILL.md

Start here

  • Read references/workflows.md for concrete transform recipes.
  • Read references/api-reference.md when you need the verified signatures or result-shape rules.
  • Read references/troubleshooting.md when modes, axes, coefficient shapes, or SWT/MRA constraints fail.
  • Run ../../scripts/check_pywavelets_install.py when you want a quick smoke check that covers the core transform stack.

Common workflow anchors

  • Use pywt.Modes.modes to confirm supported extension modes before choosing mode=.
  • For 1D smoke checks, db1 and symmetric are the safest defaults.
  • For SWT and SWT-based MRA, prefer mode='periodization' and a signal length that is a multiple of 2**level.
  • For waverec and waverecn, zero arrays are the safe way to omit coefficients; None is not the general replacement mechanism.
  • For coefficient packing, prefer coeffs_to_array / array_to_coeffs when you need a shaped array and ravel_coeffs / unravel_coeffs when you need a flat vector.
  • For fully separable transforms, inspect the returned FswavedecnResult object instead of treating it as a raw coefficient list.

Useful bundled data

  • pywt.data.ecg() is a compact 1D signal for DWT, SWT, and thresholding examples.
  • pywt.data.camera() is a compact 2D image for dwt2, wavedec2, dwtn, wavedecn, swt2, and packet-adjacent smoke checks.
  • pywt.data.nino() is useful when a transform recipe needs a small real-valued signal with a time axis.

What to expect from the references

  • references/workflows.md gives copyable recipes for 1D, 2D, ND, SWT, MRA, coefficient packing, thresholding, padding, and fully separable transforms.
  • references/api-reference.md lists the verified function signatures and the major return-shape conventions.
  • references/troubleshooting.md explains the common error fragments and recovery steps for transform and coefficient workflows.

04 同仓库更多 Skills

VectorSpaceLab
VectorSpaceLab/AREX-Skill

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.

★ 351
VectorSpaceLab
VectorSpaceLab/AREX-Skill

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.

★ 351
VectorSpaceLab
VectorSpaceLab/AREX-Skill

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.

★ 351
VectorSpaceLab
VectorSpaceLab/AREX-Skill

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.

★ 351
VectorSpaceLab
VectorSpaceLab/AREX-Skill

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.

★ 351
VectorSpaceLab
VectorSpaceLab/AREX-Skill

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).

★ 351