JuliaArrays / JuliaArrays/ArrayInterface.jl
Array Interface Test Suite
Nessuno ha ancora preso questa issue.
- Lingua principale
- Julia
- Stelle
- 140
- Fork
- 44
- Merge medio
- 4g 14h
- PR unite (30g)
- 5
Descrizione
I've come across comments that it takes many months or years before a new array type is dependable because it takes time to catch all the corner cases and bugs. I think we should be able to get an array to be safely usable for common applications in a much shorter time. It might help if we put together a set of tests for common assumptions that an array should meet so that testing is easier. For example...
function test_array_indices(x)
lininds = eachindex(IndexLinear(), x)
carinds = CartesianIndices(axes(x))
for (li,ci) = zip(lininds,carinds)
@test x[li] == x[ci]
end
@test length(lininds) == length(carinds) == length(x) == prod(size(x))
end
We could make that example a bit more verbose and inject some logging so that it's clear where errors come from.
We could also do similar things with stride-layout stuff.
Guida per i contributori
Nessuna guida per i contributori indicizzata per questo repository
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Direzione di ricerca
Inizia esaminando l'esempio test_array_indices proposto e l'organizzazione esistente dei test di array-interface, se presente. Definisci l'ambito delle assunzioni comuni sugli array e sui layout con stride, quindi conferma che la suite risultante segnali chiaramente i fallimenti e copra i casi concordati.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Valutazione
- Stack tecnologico
- julia
- Ambito
- testing
- Tipo di issue
- Funzionalità
- Difficoltà
- 5/5
- Tempo stimato
- Più di una settimana
- Stato di attività
- Ferma
- Chiarezza
- Da chiarire
- Idoneità per principianti
- 30/100