Skip to content

Commit 6f74156

Browse files
committed
Add Artifacts.toml for the npy files
1 parent 540ef1d commit 6f74156

File tree

4 files changed

+25
-5
lines changed

4 files changed

+25
-5
lines changed

benchmarks/Artifacts.toml

+15
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
[punched_pmn]
2+
git-tree-sha1 = "f225ac0deac2e86eebd5b79884fa74aae3b0772c"
3+
lazy = true
4+
5+
[[punched_pmn.download]]
6+
sha256 = "71a26d6799a1f60cc4dd2f56a670c903b8fad483a5752beb85495de55f7d7844"
7+
url = "https://github.com/exanauts/CompressedSensingIPM-data/raw/refs/heads/main/punched_pmn.tar.gz"
8+
9+
[z3d_movo]
10+
git-tree-sha1 = "94c7cdf175da37afc308dd73bb6ab3df58bb5e71"
11+
lazy = true
12+
13+
[[z3d_movo.download]]
14+
sha256 = "42c844714629e3f5fb0e2fa6a65a1443cc04d90705ccfc7aa736bb30eb9ec6e3"
15+
url = "https://github.com/exanauts/CompressedSensingIPM-data/raw/refs/heads/main/z3d_movo.tar.gz"

benchmarks/Manifest.toml

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
julia_version = "1.11.5"
44
manifest_format = "2.0"
5-
project_hash = "2666337025370a30df588af12f9e237460cb4cef"
5+
project_hash = "494b26c5879bbcc087d16564fa42a65dc3279867"
66

77
[[deps.AMD]]
88
deps = ["LinearAlgebra", "SparseArrays", "SuiteSparse_jll"]

benchmarks/Project.toml

+1
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@ DelimitedFiles = "8bb1440f-4735-579b-a4ab-409b98df4dab"
77
Distributions = "31c24e10-a181-5473-b8eb-7969acd0382f"
88
FFTW = "7a1cc6ca-52ef-59f5-83cd-3a7055c09341"
99
LaplaceInterpolation = "afb1b68e-e51f-4e49-a799-0e085170423d"
10+
LazyArtifacts = "4af54fe1-eca0-43a8-85a7-787d91b784e3"
1011
LinearAlgebra = "37e2e46d-f89d-539d-b4ee-838fcccc9c8e"
1112
MadNLP = "2621e9c9-9eb4-46b1-8089-e8c72242dfb6"
1213
MadNLPGPU = "d72a61cc-809d-412f-99be-fd81f4b8a598"

benchmarks/crystal.jl

+8-4
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,10 @@ using LinearAlgebra, SparseArrays
33
using LaplaceInterpolation, NPZ
44
using DelimitedFiles
55
using MadNLP, MadNLPGPU, CUDA
6-
using Test
6+
using Test, LazyArtifacts
7+
8+
include("../test/fft_wei.jl")
9+
include("../test/punching_centering.jl")
710

811
function ipm_solve!(solver::MadNLP.MadNLPSolver)
912
MadNLP.print_init(solver)
@@ -27,7 +30,7 @@ function punch_3D_cart(center, radius, x, y, z; linear = false)
2730
end
2831
end
2932

30-
function fft_vishwas(z3d; variant::Bool=false, gpu::Bool=false, rdft::Bool=false)
33+
function crystal(z3d; variant::Bool=false, gpu::Bool=false, rdft::Bool=false)
3134
if !variant
3235
dx = 0.02
3336
dy = 0.02
@@ -128,8 +131,9 @@ end
128131
gpu = true
129132
rdft = false
130133
variant = true
131-
z3d = variant ? npzread("../punched_pmn") : npzread("../z3d_movo.npy")
132-
nlp, solver, results, timer = fft_vishwas(z3d; variant, gpu, rdft)
134+
path_z3d = variant ? joinpath(artifact"punched_pmn", "punched_pmn.npy") : joinpath(artifact"z3d_movo", "z3d_movo.npy")
135+
z3d = npzread(path_z3d)
136+
nlp, solver, results, timer = crystal(z3d; variant, gpu, rdft)
133137
N = length(results.solution) ÷ 2
134138
beta_MadNLP = results.solution[1:N]
135139
println("Timer: $(timer)")

0 commit comments

Comments
 (0)