Code indexing in gitaly is broken and leads to code not being visible to the user. We work on the issue with highest priority.

Skip to content
Snippets Groups Projects

Resolve "mixed-precision"

Merged montan_v requested to merge 146-mixed-precision into master
Compare and
15 files
+ 1397
7
Compare changes
  • Side-by-side
  • Inline
Files
15
@@ -33,26 +33,28 @@
namespace ippl {
/*
* @class OrthogonalRecursiveBisection
* @tparam T
* @tparam Tf type of field
* @tparam Dim dimension
* @tparam M mesh
* @tparam Tp type of particle position. If not specified, it will be equal to the field's type
*/
template <class T, unsigned Dim, class Mesh, class Centering>
template <class Tf, unsigned Dim, class Mesh, class Centering, class Tp = Tf>
class OrthogonalRecursiveBisection {
public:
using view_type = typename detail::ViewType<T, Dim>::view_type;
using field_view_type = typename detail::ViewType<Tf, Dim>::view_type;
// Weight for reduction
Field<T, Dim, Mesh, Centering> bf_m;
Field<Tf, Dim, Mesh, Centering> bf_m;
/*!
* Initialize member field with mesh and field layout
* @param fl FieldLayout
* @param fl
* @param mesh Mesh
* @param rho Density field
*/
void initialize(FieldLayout<Dim>& fl, UniformCartesian<T, Dim>& mesh,
const Field<T, Dim, Mesh, Centering>& rho);
void initialize(FieldLayout<Dim>& fl, Mesh& mesh,
const Field<Tf, Dim, Mesh, Centering>& rho);
/*!
* Performs scatter operation of particle positions in field (weights) and
@@ -61,7 +63,7 @@ namespace ippl {
* @param fl FieldLayout
* @param isFirstRepartition boolean which tells whether to scatter or not
*/
bool binaryRepartition(const ParticleAttrib<Vector<T, Dim>>& R, FieldLayout<Dim>& fl,
bool binaryRepartition(const ParticleAttrib<Vector<Tp, Dim>>& R, FieldLayout<Dim>& fl,
const bool& isFirstRepartition);
/*!
@@ -77,13 +79,13 @@ namespace ippl {
* @param dom Domain to reduce
* @param cutAxis Index of cut axis
*/
void perpendicularReduction(std::vector<T>& res, unsigned int cutAxis, NDIndex<Dim>& dom);
void perpendicularReduction(std::vector<Tf>& res, unsigned int cutAxis, NDIndex<Dim>& dom);
/*!
* Find median of array
* @param w Array of real numbers
*/
int findMedian(std::vector<T>& w);
int findMedian(std::vector<Tf>& w);
/*!
* Splits the domain given by the iterator along the cut axis at the median,
@@ -101,7 +103,7 @@ namespace ippl {
* Scattering of particle positions in field using a CIC method
* @param r Weights
*/
void scatterR(const ParticleAttrib<Vector<T, Dim>>& r);
void scatterR(const ParticleAttrib<Vector<Tp, Dim>>& r);
}; // class
Loading