Skip to content

X^T*B doesn't call BLAS gemm #1278

Closed
@fardream

Description

@fardream

For matrix $A$, $B$, calculating $A^TB$ should be able to use gemm routine, however, it doesn't

let a = Array2::<f64>::zeros((10000, 1000));
let b = Array2::<f64>::zeros((10000, 1000));
let _ = a.t().dot(&b);

However, if $A^T$ is provided directly, it will call gemm

let b = Array2::<f64>::zeros((10000, 1000));
let at = Array2::<f64>::zeros((1000, 10000));
let _ = at.dot(&b);

See code example here

https://github.com/fardream/rust-ndarray-t-dot

Related to #445

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions