Hacktoberfest 2026: die Issues, die Maintainer für den Oktober markiert haben – offen und einsteigerfreundlich. Hacktoberfest-Issues durchsuchen

ArrayPartition of GPU arrays: norm, dot, Vector, any scalar-index; no KernelAbstractions.get_backend

Offen
#676 0 Kommentare 0 Reaktionen 0 zugewiesene Personen Auf GitHub ansehen

Maintainer antworten meist innerhalb von 2 Tagen

Dieses Issue hat noch niemand übernommen.

Bewertung

Schwierigkeit
4/5
Geschätzter Aufwand
3-5 Tage
Anfängerfreundlichkeit
45/100
Issue-Typ
Bug
Klarheit
Größtenteils klar
Aktivitätsstatus
Aktiv
Bereich
backend

Rechercherichtung

Start by locating ArrayPartition's generic AbstractArray operations and existing partition-wise methods; the issue names no source files or tests. Reproduce the examples with JLArrays and allowscalar(false), then investigate KernelAbstractions.get_backend support and the reported method invalidations. Done means the listed operations avoid scalar indexing and backend lookup works, with invalidation effects considered.

Vom Indexierungsmodell aus dem Issue-Text verfasst.

Beschreibung

An ArrayPartition of GPU arrays fails several common operations under allowscalar(false). Broadcast, sum, copyto!, fill! and Tsit5 solves work.

using RecursiveArrayTools, JLArrays, LinearAlgebra
JLArrays.allowscalar(false)
ap = ArrayPartition(JLArray([1.0, 2.0]), JLArray([3.0, 4.0]))
sum(ap)          # works
norm(ap)         # ErrorException: Scalar indexing is disallowed.
dot(ap, ap)      # scalar indexing
Vector(ap)       # scalar indexing
any(isnan, ap)   # scalar indexing (without RecursiveArrayToolsArrayPartitionAnyAll)

These fall back to generic element-by-element AbstractArray iteration. Partition-wise methods would fix this, and they are also much faster on CPU: dot takes 1014 ns elementwise and 70 ns partition-wise on a mixed 5-partition AP. The audit measured 21 invalidations from adding dot/norm methods, so this needs a decision.

Related gap found while fixing https://github.com/SciML/OrdinaryDiffEq.jl/issues/4813: KernelAbstractions.get_backend(ArrayPartition(JLArray(...), ...)) throws "Implement get_backend(::ArrayPartition…)". OrdinaryDiffEq's default discontinuity-bracketing setup for continuous callbacks hits this.

Found in a measurement audit of RecursiveArrayTools.jl master 02c477c (v4.5.3). It reproduces on Julia 1.12.4 and 1.10.12, and the reproducer above was re-run as written before filing.

🤖 Filed by Claude Code (model: claude-opus-5-5[1m]) on behalf of @ChrisRackauckas. The audit was done by a Claude Code Opus 5.5 subagent. Session: https://claude.ai/code/session_01LPHREnnonfLg1VcE1EJovv

Vorherrschende Sprache
Julia
Sterne
234
Forks
77
Ø Merge
1 T. 5 Std.
Gemergte PRs (30 T.)
10

Entwicklungsumgebung

Erste Schritte

  1. Lesen Sie das ganze Issue und danach den Beitragsleitfaden des Projekts.
  2. Schreiben Sie ins Issue, dass Sie es übernehmen — das erspart doppelte Arbeit.
  3. Forken Sie das Repository und arbeiten Sie in einem Branch.
  4. Öffnen Sie einen Pull Request, der die Issue-Nummer nennt.

Mehr aus SciML/RecursiveArrayTools.jl

Alle Issues in SciML/RecursiveArrayTools.jl

Ähnliche Issues

Weitere Issues zu Julia

Neue Issues direkt in Ihr Postfach

Eine kurze Übersicht über anfängerfreundliche GitHub-Issues.