sph methods slow?
Dieses Issue hat noch niemand übernommen.
Bewertung
- Schwierigkeit
- 4/5
- Geschätzter Aufwand
- 3-5 Tage
- Anfängerfreundlichkeit
- 25/100
- Issue-Typ
- Bug
- Klarheit
- Muss geklärt werden
- Aktivitätsstatus
- Veraltet
- Tech-Stack
- julia
- Bereich
- performance
Rechercherichtung
Reproduziere die gemeldeten Laufzeiten mit plan_sph2fourier, plan_sph_synthesis, lmul! und den FFTW-Vergleichen im Issue. Beginne damit, diese Einstiegspunkte für sphärische Transformationen zu lokalisieren und sowohl die Fälle mit großen als auch mit kleinen Arrays zu profilieren. Als abgeschlossen würde gelten, wenn die gemeldete Verlangsamung oder die Allokationen identifiziert und behoben wurden; das Issue definiert jedoch kein spezifisches Ziel oder keinen Test.
Vom Indexierungsmodell aus dem Issue-Text verfasst.
Beschreibung
Maybe this is totally expected, but:
- A lot slower than FFT. It has been a while, but I seem to recall (going back to 2018) that the first version was much more comparable to FFT
- Allocations that don't go away with in-place (hard to make an efficient time evolution algorithm in this case)
- Which method is the bottleneck depends on size
using FastTransforms
using FFTW
using LinearAlgebra
n,m = 1024,2047
x = randn(ComplexF64,n,m)
# FFTW
@time fft(x);
0.033259 seconds (259 allocations: 32.001 MiB)
P! = plan_fft!(x);
@time P!*x;
0.035154 seconds (232 allocations: 14.969 KiB)
# Spherical
P = plan_sph2fourier(x)
PS = plan_sph_synthesis(x)
@time PS*(P*x);
0.235185 seconds (549 allocations: 127.972 MiB, 1.57% gc time)
@time P*x; # slow
0.145820 seconds (8 allocations: 63.969 MiB, 1.85% gc time)
@time PS*x;
0.051036 seconds (545 allocations: 64.003 MiB)
@time lmul!(P,x); # slow
0.139856 seconds (4 allocations: 31.984 MiB, 0.91% gc time)
@time lmul!(PS,x);
0.047418 seconds (539 allocations: 32.018 MiB)
## small array
n,m = 60,121
x = randn(ComplexF64,n,m);
# FFTW
@time fft(x);
0.000560 seconds (242 allocations: 129.836 KiB)
P! = plan_fft!(x);
@time P!*x;
0.000411 seconds (218 allocations: 14.492 KiB)
# Spherical
P = plan_sph2fourier(x);
PS = plan_sph_synthesis(x);
@time PS*(P*x);
0.101827 seconds (19.31 k allocations: 1.626 MiB)
@time P*x;
0.000266 seconds (8 allocations: 227.406 KiB)
@time PS*x; # slow
0.031964 seconds (20.48 k allocations: 1.440 MiB)
@time lmul!(P,x);
0.000364 seconds (4 allocations: 113.594 KiB)
@time lmul!(PS,x); # slow
0.037324 seconds (20.38 k allocations: 1.326 MiB)
- Vorherrschende Sprache
- Julia
- Sterne
- 284
- Forks
- 28
- Ø Merge
- 9 Std. 21 Min.
- Gemergte PRs (30 T.)
- 2
Entwicklungsumgebung
Dieses Projekt bietet weder Dev-Container noch Dockerfile noch Beitragsleitfaden – die Einrichtung liegt bei Ihnen. Beginnen Sie mit der README; die allgemeinen Schritte stehen in unserem Leitfaden für den ersten Beitrag.
Erste Schritte
- Lesen Sie das ganze Issue und danach den Beitragsleitfaden des Projekts.
- Schreiben Sie ins Issue, dass Sie es übernehmen — das erspart doppelte Arbeit.
- Forken Sie das Repository und arbeiten Sie in einem Branch.
- Öffnen Sie einen Pull Request, der die Issue-Nummer nennt.
Mehr aus JuliaApproximation/FastTransforms.jl
-
Loading FastTransforms.jl can make FFTs via FFTW.jl 100x slower due to threading conflictsEvtl. vergeben @dlfivefifty hat das vor 118 Tagen übernommen. Offen
JuliaApproximation/FastTransforms.jl#267 · 2 Reaktionen · 2 zugewiesene Personen ·
-
Schwierigkeit 3/5 1-2 Tage Anfängerfreundlichkeit 38/100
JuliaApproximation/FastTransforms.jl#266 · 1 Kommentar ·
-
Schwierigkeit 4/5 3-5 Tage Anfängerfreundlichkeit 42/100
JuliaApproximation/FastTransforms.jl#263 · 2 Kommentare ·
-
Schwierigkeit 4/5 3-5 Tage Anfängerfreundlichkeit 35/100
JuliaApproximation/FastTransforms.jl#257 · 1 Kommentar ·
-
Allocating lmul!Offen
Schwierigkeit 4/5 3-5 Tage Anfängerfreundlichkeit 25/100
JuliaApproximation/FastTransforms.jl#253 · 7 Kommentare ·
Alle Issues in JuliaApproximation/FastTransforms.jl
Ähnliche Issues
-
backport 1.14 GC
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 66/100
Maintainer antworten meist innerhalb von 1 Tag
-
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 72/100
JuliaDiff/TaylorSeries.jl#445 ·
-
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 75/100
control-toolbox/CTActions#139 · 1 Kommentar ·
Maintainer antworten meist innerhalb von 1 Tag
-
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 83/100
SciML/Optimization.jl#1448 ·
Maintainer antworten meist innerhalb von 1 Tag
-
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 84/100
SciML/PETScDiffEq.jl#362 ·
Maintainer antworten meist innerhalb von 1 Tag