function read_mesons(path::String,g1::Union{String,Nothing}=nothing,g2::Union{String,Nothing}=nothing;id::Union{String,Nothing}=nothing,legacy::Bool=false)
function read_mesons(path::String,g1::Union{String,Nothing}=nothing,g2::Union{String,Nothing}=nothing;id::Union{String,Nothing}=nothing,legacy::Bool=false,
@@ -144,13 +147,13 @@ function read_mesons(path::String, g1::Union{String, Nothing}=nothing, g2::Union
tmp=Array{Float64}(undef,tvals*nnoise)
read!(data,tmp)
tmp2=reshape(tmp,(nnoise,tvals))
tmp2=mean(tmp2,dims=1)
tmp2=mean(tmp2[1:nnoise_trunc,:],dims=1)
data_re[c,icfg,:]=tmp2[1,:]
elseifc_header[k].is_real==0
tmp=Array{Float64}(undef,2*tvals*nnoise)
read!(data,tmp)
tmp2=reshape(tmp,(2,nnoise,tvals))
tmp2=mean(tmp2,dims=2)
tmp2=mean(tmp2[:,1:nnoise_trunc,:],dims=2)
data_re[c,icfg,:]=tmp2[1,1,:]
data_im[c,icfg,:]=tmp2[2,1,:]
...
...
@@ -172,8 +175,9 @@ function read_mesons(path::String, g1::Union{String, Nothing}=nothing, g2::Union
returnres
end
function read_mesons(path::Vector{String},g1::Union{String,Nothing}=nothing,g2::Union{String,Nothing}=nothing;id::Union{String,Nothing}=nothing,legacy::Bool=false)
res=read_mesons.(path,g1,g2,id=id,legacy=legacy)
function read_mesons(path::Vector{String},g1::Union{String,Nothing}=nothing,g2::Union{String,Nothing}=nothing;id::Union{String,Nothing}=nothing,legacy::Bool=false,