Extend the number_particles interface function with this function and default implementation:
@inline function number_particles(
proc_def::AbstractProcessDefinition, dir::DIR, ::PT
) where {DIR<:ParticleDirection,PT<:AbstractParticleType}
return count(x -> x isa PT, particles(proc_def, dir))
end
Opening this as an issue instead of a PR because of the ongoing refactoring. It will be easier to add this (then in QEDbase.jl) once that is done.
Extend the
number_particles
interface function with this function and default implementation:Opening this as an issue instead of a PR because of the ongoing refactoring. It will be easier to add this (then in QEDbase.jl) once that is done.