t3toolbox.tucker_tensor_train#

This module contains type aliases and basic backend for Tucker tensor trains.

Tucker tensor trains:#

  • TuckerTensorTrain
    The cores of a Tucker tensor train with varied ranks
    (tucker_cores, tt_cores)
  • T3Structure
    The structure of a Tucker tensor train.
    (shape, tucker_ranks, tt_ranks)
  • EdgeWeights
    Weights for edges of a Tucker tensor train
    (tucker_weights, tt_weights)
  • T3Base
    Base cores for Tucker tensor trains in base-variation format
    (up_tucker_cores, left_tt_cores, right_tt_cores, outer_tt_cores)
  • T3Variation
    Variation cores for Tucker tensor trains in base-variation format
    (tucker_variations, tt_variations)
  • BVStructure
    The structure of a Tucker tensor train in base-variation format
    (shape, up_ranks, outer_ranks, left_ranks, right_ranks)
  • BVEdgeWeights
    Weights for the edges of a Tucker tensor train in base-variation format
    (shape_weights, up_weights, outer_weights, left_weights, right_weights)

Uniform Tucker tensor trains:#

  • UniformTuckerTensorTrain
    Supercores of a uniform Tucker tensor train with uniform ranks
    (tucker_supercore, tt_supercore)
  • UniformT3Structure
    The structure of a uniform Tucker tensor train.
    (num indices d, index size N, tucker rank nU, TT rank r)
  • UniformEdgeWeights
    Weights for the edges of a uniform Tucker tensor train
    (tucker_weights, tt_weights)
  • UniformT3Base
    Base cores for Tucker tensor trains in base-variation format
    (up_tucker_supercore, left_tt_supercore, right_tt_supercore, outer_tt_supercore)
  • UniformT3Variation
    Variation cores for Tucker tensor trains in base-variation format
    (tucker_variations_supercore, tt_variations_supercore)
  • BVStructure
    The structure of a Tucker tensor train in base-variation format
    (num indices d, index size N, up rank nU, outer rank nO, left rank rL, right rank rR)
  • UniformBVEdgeWeights
    Weights for the edges of a Tucker tensor train in base-variation format
    (shape_weights, up_weights, outer_weights, left_weights, right_weights)

Other#

Operations here are defined with respect to the dense N0 x … x N(d-1) tensors that are represented by the Tucker tensor train, even though these dense tensors are not formed during computations.

For corewise backend, see t3toolbox.corewise

Classes#

TuckerTensorTrain

Tucker tensor train with variable ranks.

Functions#

t3_stack(...)

Stacks an array-like structure of TuckerTensorTrains into one stacked TuckerTensorTrain.

t3_core_shapes(...)

Compute the tucker and TT backend shapes for a Tucker tensor train.

compute_minimal_t3_ranks(...)

Find minimal ranks for a generic Tucker tensor train with a given structure.

t3_zeros(, use_jax)

Construct a Tucker tensor train of zeros.

t3_corewise_randn(, use_jax)

Construct a Tucker tensor train with random cores.

t3_save(→ None)

Save a Tucker tensor train to a file.

t3_load(→ TuckerTensorTrain)

Load a Tucker tensor train from a file.

t3_to_vector(→ t3toolbox.backend.common.NDArray)

Converts a TuckerTensorTrain into a 1D vector containing the backend entries.

t3_from_vector() → TuckerTensorTrain)

Constructs a TuckerTensorTrain from a 1D vector containing the backend entries.

t3_apply(→ t3toolbox.backend.common.NDArray)

Contract a Tucker tensor train with vectors in all indices.

t3_entries(→ t3toolbox.backend.common.NDArray)

Compute an entry (or multiple entries) of a Tucker tensor train.

t3_probe(...)

Probe a TuckerTensorTrain.

t3_add(→ TuckerTensorTrain)

Add Tucker tensor trains x and y, yielding a Tucker tensor train x+y with summed ranks.

t3_sub(...)

Subtract Tucker tensor trains, x - y, yielding a Tucker tensor train with summed ranks.

t3_inner_product(x, y[, use_orthogonalization, use_jax])

Compute Hilbert-Schmidt inner product of two Tucker tensor trains.

t3svd_dense(...)

Compute TuckerTensorTrain and edge singular values for dense tensor.

t3svd(...)

Compute (truncated) T3-SVD of TuckerTensorTrain.