`lax::UPLO` references column-major layout
Nadie ha tomado este issue todavía.
Evaluación
- Dificultad
- 5/5
- Tiempo estimado
- Más de una semana
- Aptitud para principiantes
- 25/100
Línea de trabajo
Start with ndarray-linalg/src/eigh.rs around line 127 and reproduce the supplied Rust example using both UPLO variants. Read the UPLO documentation and compare the behavior for the array layouts described; done requires a decided, documented strategy for layout handling, including the tuple-of-arrays case.
Escrito por el modelo de indexación a partir del texto del issue.
Descripción
Hello everyone, thanks for the great work.
Disclaimer: I'm new to LAPACK & scientific computing in general, apologies if what follows is not perfectly rigorous.
I've noticed that the UPLO flag does not necessarily do what we expect, in the sense that it references the column-major alignment of the data. In particular, I'm not sure this aligns with newcomers' expectations.
To wit, in the following example:
extern crate ndarray;
extern crate ndarray_linalg;
use ndarray::*;
use ndarray_linalg::*;
fn main() {
// A very clearly upper-diagonal matrix
let a = arr2(&[[3.0, 1.0, 1.0], [0.0, 3.0, 1.0], [0.0, 0.0, 3.0]]);
// Works with UPLO::Lower, not UPLO::Upper...
let (e, vecs) = a.eigh(UPLO::Lower).unwrap();
println!("eigenvalues = \n{:?}", e);
println!("V = \n{:?}", vecs);
let av = a.dot(&vecs);
println!("AV = \n{:?}", av);
}
Using UPLO::Upper does not work, even though the matrix is clearly upper-diagonal in ndarray-world.
It looks like this stems from this method, perhaps we should transpose uplo in that case? Note that in the case of a tuple of arrays, we should probably assert that both arrays have the same layout, otherwise it does not make sense to call uplo.t().
It might make sense to decide that UPLO is column-major only, and leave the responsibility to the caller. But in that case I think we should document that behaviour in UPLO's documentation.
I'm happy to propose a PR, let me know which strategy seems best to you.
- Lenguaje dominante
- Rust
- Estrellas
- 452
- Forks
- 95
- Métricas de merge de PR
- Sin PR fusionados en 30 d
Preparar el entorno
Aún no hemos revisado los archivos de configuración de este proyecto. Empieza por su README y consulta nuestra guía para la primera contribución para los pasos generales.
Primeros pasos
- Lee el issue completo y luego la guía de contribución del proyecto.
- Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
- Haz un fork del repositorio y trabaja en una rama.
- Abre un pull request que haga referencia al número del issue.
Más de rust-ndarray/ndarray-linalg
-
Thin SVDAbierto
Dificultad 5/5 Más de una semana Aptitud para principiantes 38/100
rust-ndarray/ndarray-linalg#414 ·
-
Dificultad 5/5 Más de una semana Aptitud para principiantes 30/100
rust-ndarray/ndarray-linalg#413 · 1 comentario ·
-
Cyclically Tridiagonal Matrices?Abierto
Dificultad 5/5 Más de una semana Aptitud para principiantes 25/100
rust-ndarray/ndarray-linalg#404 ·
-
SIGSEGV on qr decompositionAbierto
Dificultad 4/5 3-5 días Aptitud para principiantes 35/100
rust-ndarray/ndarray-linalg#402 · 1 comentario ·
-
Dificultad 4/5 3-5 días Aptitud para principiantes 35/100
rust-ndarray/ndarray-linalg#401 · 2 reacciones ·
Todos los issues de rust-ndarray/ndarray-linalg
Issues similares
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 84/100
vercel-labs/agent-browser#2017 ·
Los mantenedores suelen responder en 1 día
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 72/100
tursodatabase/turso#9405 ·
Los mantenedores suelen responder en 1 día
-
bug
Dificultad 2/5 1-3 horas Aptitud para principiantes 72/100
PolyMeilex/Neothesia#447 ·
Los mantenedores suelen responder en 1 día
-
backend::vllm diffusion multimodal
Dificultad 2/5 1-3 horas Aptitud para principiantes 72/100
Los mantenedores suelen responder en 1 día
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 68/100
trezor/trezor-firmware#7985 ·
Los mantenedores suelen responder en 2 días