I/O interface for astrophysical simulation codes
]add AstroIO
or
]add https://github.com/JuliaAstroSim/AstroIO.jl
using AstroIO
Suffixes gadget2
, Gadget2
, GADGET2
are supported
header, data = read_gadget2("snapshot.gadget2")
write_gadget2("output.Gadget2", header, data)
# If only data provided, a default header would be generated
write_gadget2("output.GADGET2", data)
header, data = load("snapshot.gadget2")
save("FileIO.gadget2", header, data)
write_csv("output", csv) # No suffix
write_gadget2_jld("output.jld2", header, data)
write_jld("NoHeader.jld2", data)
header, data = read_gadget2_jld("output.jld2")
data = read("NoHeader.jld2")
# Or simply use JLD2 interfaces
@load "NoHeader.jld2"
- Basic data structure: PhysicalParticles.jl
- File I/O: AstroIO.jl
- Initial Condition: AstroIC.jl
- Parallelism: ParallelOperations.jl
- Trees: PhysicalTrees.jl
- Meshes: PhysicalMeshes.jl
- Plotting: AstroPlot.jl
- Simulation: ISLENT
Welcome issues and PRs. Need help for other snapshot formats.