Skip to main content

Crate oxicuda_seq

Crate oxicuda_seq 

Source
Expand description

oxicuda-seq — Sequence Models & Structured Prediction for OxiCUDA.

§Architecture

oxicuda-seq
├── hmm/          — Hidden Markov Models (discrete/Gaussian), forward-backward, Viterbi, Baum-Welch
├── crf/          — Linear-chain CRF: forward-backward in score space, L-BFGS training, Viterbi decoding
├── memm/         — Maximum-Entropy Markov Models
├── ssvm/         — Structured SVM (linear-chain) with cutting-plane optimisation
├── structured/   — Sinkhorn CRF: entropy-regularised optimal-transport normalisation
├── beam/         — Generic beam search with length normalisation and diversity penalty
├── ctc/          — CTC loss (forward-backward) + greedy / prefix-beam decoding
├── decoders/     — Stochastic decoders: top-k, nucleus (top-p), typical sampling
├── alignment/    — Needleman-Wunsch, Smith-Waterman, Gotoh affine-gap, Hirschberg
├── grid_crf/     — Pairwise 2D CRF + mean-field inference
├── kalman/       — Linear/EKF Kalman filter, RTS smoother, EM parameter learning
├── mrf/          — General MRF + Ising, Gibbs sampler, loopy belief propagation
├── perceptron/   — Structured + averaged perceptron sequence taggers (Collins 2002)
├── matching/     — Aho–Corasick multi-pattern matching automaton
├── string/       — Manacher longest-palindrome, suffix automaton (DAWG),
│                   Z-algorithm, suffix array + LCP (SA-IS/Kasai), BWT/FM-index
├── tagging/      — BIO/BIOES conversion + validation, span-based F1 (seqeval)
└── metrics/      — Token/sequence accuracy, edit distance, BLEU, perplexity, log-loss

NOTE on lints: numerical kernels in this crate use straight integer-index loops (for i in 0..n) because every body indexes multiple parallel arrays. Rewriting them in iterator form obscures the math and forces awkward zip chains, so clippy::needless_range_loop is allowed crate-wide.

Re-exports§

pub use error::SeqError;
pub use error::SeqResult;
pub use handle::LcgRng;
pub use handle::SeqHandle;
pub use handle::SmVersion;

Modules§

align
Wavefront-based sequence alignment.
alignment
Sequence-alignment algorithms.
beam
Generic beam search infrastructure.
crf
Linear-chain Conditional Random Fields (CRF).
ctc
Connectionist Temporal Classification (CTC).
decoders
Stochastic decoders for autoregressive sequence generation.
distance
String-distance algorithms.
error
Error types for oxicuda-seq.
folding
RNA secondary-structure folding algorithms.
grid_crf
2-D pairwise CRF + mean-field variational inference + loopy BP.
handle
Handle and RNG primitives for oxicuda-seq.
hmm
Hidden Markov Models: discrete + Gaussian emissions, forward-backward, Viterbi decoding, and Baum-Welch (EM) parameter learning. Also includes Variational Bayes EM (Dirichlet priors) and Hidden Semi-Markov Models with explicit duration distributions.
kalman
Linear / Extended Kalman filtering, RTS smoothing, EM parameter learning, Unscented Kalman Filter, and Particle Filter.
matching
Multi-pattern and exact string-matching automata.
memm
Maximum-Entropy Markov Models (MEMM): per-state softmax classifiers over the previous label plus features.
metrics
Evaluation metrics for sequence models.
mrf
General Markov Random Fields (graph + Ising), Gibbs sampler, loopy belief propagation.
perceptron
Structured-perceptron sequence taggers (Collins 2002), including the averaged-perceptron variant.
ptx_kernels
GPU PTX kernels for Sequence Models & Structured Prediction.
ssvm
Structured SVM with cutting-plane optimisation for linear-chain prediction.
string
Classical string algorithms.
structured
Differentiable structured-prediction layers.
tagging
Tag-scheme utilities for sequence labelling: BIO / BIOES conversion and validation, entity-span extraction, and span-based (entity-level) F1 (seqeval semantics).