Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bug fix in LegendHDF5IO extension and restructure tests #428

Merged
merged 11 commits into from
Nov 5, 2024
3 changes: 2 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -6,4 +6,5 @@ Manifest.toml
.ipynb_checkpoints
*.ipynb
.vscode*
*.gdml
*.gdml
test/*h5
4 changes: 2 additions & 2 deletions Project.toml
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ Format = "1.2, 1.3"
GPUArrays = "8, 9, 10"
Geant4 = "0.1.13"
Interpolations = "0.14, 0.15"
IntervalSets = "0.5, 0.6, 0.7"
IntervalSets = "0.6, 0.7"
JSON = "0.21.2"
KernelAbstractions = "0.8, 0.9"
LaTeXStrings = "1.1"
Expand All @@ -66,7 +66,7 @@ Parameters = "0.12"
PolygonOps = "0.1"
Polynomials = "2, 3, 4"
ProgressMeter = "1.5"
RadiationDetectorSignals = "0.3"
RadiationDetectorSignals = "0.3.5"
Random = "<0.0.1, 1"
RecipesBase = "1.0, 1.1, 1.2, 1.3"
Requires = "1.1, 1.2, 1.3"
Expand Down
7 changes: 4 additions & 3 deletions ext/SolidStateDetectorsLegendHDF5IOExt.jl
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,9 @@ module SolidStateDetectorsLegendHDF5IOExt
import ..LegendHDF5IO

using SolidStateDetectors
using SolidStateDetectors: RealQuantity, SSDFloat
using SolidStateDetectors: RealQuantity, SSDFloat, to_internal_units, chunked_ranges
using TypedTables, Unitful
using Format

function SolidStateDetectors.ssd_write(filename::AbstractString, sim::Simulation)
if isfile(filename) @warn "Destination `$filename` already exists. Overwriting..." end
Expand Down Expand Up @@ -49,8 +50,8 @@ function SolidStateDetectors.simulate_waveforms( mcevents::TypedTables.Table, si
@info "Now simulating $(evtrange) and storing it in\n\t \"$ofn\""
mcevents_sub = simulate_waveforms(mcevents[evtrange], sim; Δt, max_nsteps, diffusion, self_repulsion, number_of_carriers, number_of_shells, verbose)

LegendHDF5IO.lh5open(ofn, "w") do output
LegendHDF5IO.writedata(output, "generated_waveforms", mcevents_sub)
LegendHDF5IO.lh5open(ofn, "w") do h5f
LegendHDF5IO.writedata(h5f.data_store, "generated_waveforms", mcevents_sub)
end
end
end
Expand Down
201 changes: 0 additions & 201 deletions test/ADLChargeDriftModel.jl

This file was deleted.

45 changes: 0 additions & 45 deletions test/IO.jl

This file was deleted.

3 changes: 3 additions & 0 deletions test/Project.toml
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
[deps]
ArraysOfArrays = "65a8f2f4-9b39-5baf-92e2-a9cc46fdf018"
Geant4 = "559df036-b7a0-42fd-85df-7d5dd9d70f44"
LegendDataTypes = "99e09c13-5545-5ee2-bfa2-77f358fb75d8"
LegendHDF5IO = "c9265ca6-b027-5446-b1a4-febfa8dd10b0"
LinearAlgebra = "37e2e46d-f89d-539d-b4ee-838fcccc9c8e"
OrderedCollections = "bac558e1-5e72-5ebc-8fee-abe8a469f55d"
Expand All @@ -16,3 +18,4 @@ Unitful = "1986cc42-f94f-5a68-af5c-568840ba703d"

[compat]
LegendHDF5IO = "0.1"
LegendDataTypes = "0.1.3"
Loading
Loading