TTCross: Tensor-Train Decomposition by TRCross

Description Usage Arguments Value Author(s) References Examples

Description

TTCross incrementaly decomposes the input tensor by skeleton decomposition algorithm. The algorithm only select the row/column indices and any large temporal matrix are genrated in the process. Therefore, this method is suitable for the sparse tensor.

Usage

1
TTCross(A, Ranks=NULL, thr=1E-10, num.iter=30)

Arguments

A

The input sparse tensor.

Ranks

TT-ranks to specify the lower dimensions.

thr

The threshold to determine the convergence (Default: 1E-10).

num.iter

The number of iteration (Default: 30).

Value

G : Core tensors

Author(s)

Koki Tsuyuzaki

References

I. V. Oseledets, et. al., (2010). TT-cross approximation for multidimensional arrays. Linear Algebra and its Applications

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
library("rTensor")
library("tensorr")
# Sparse Tensor data
X1 <- array(rnorm(3*5*7*9*11), c(3,5,7,9,11))
dimnames(X1) <- list(
    I=paste0("i", 1:3),
    J=paste0("j", 1:5),
    K=paste0("k", 1:7),
    L=paste0("l", 1:9),
    M=paste0("m", 1:11)
    )
X1 <- as.tensor(X1)
X2 <- as_sptensor(dtensor(X1@data))
dimnames(X2) <- dimnames(X1@data)
# TT-ranks
Ranks <- c(p=2, q=4, r=6, s=8)
# TT-Cross
out.TTCross <- TTCross(X2, Ranks, num.iter=2)

ttTensor documentation built on May 18, 2021, 5:07 p.m.