Commit c5b702ab authored by Martin Reinecke's avatar Martin Reinecke
Browse files

namespace mr -> ducc0

parent f149f19c
...@@ -66,8 +66,8 @@ Candidates for testing the validity of the Healpix routines: ...@@ -66,8 +66,8 @@ Candidates for testing the validity of the Healpix routines:
//#include "powspec.h" //#include "powspec.h"
using namespace std; using namespace std;
using namespace mr; using namespace ducc0;
using namespace mr::healpix; using namespace ducc0::healpix;
#define UNITTESTS #define UNITTESTS
......
...@@ -38,11 +38,11 @@ ...@@ -38,11 +38,11 @@
#include "ducc0/math/constants.h" #include "ducc0/math/constants.h"
using namespace std; using namespace std;
using namespace mr; using namespace ducc0;
static void threading_status(void) static void threading_status(void)
{ {
cout << "Threading: " << mr::get_default_nthreads() << " threads active." << endl; cout << "Threading: " << ducc0::get_default_nthreads() << " threads active." << endl;
} }
static void MPI_status(void) static void MPI_status(void)
...@@ -124,7 +124,7 @@ static double allreduceSumDouble (double val) ...@@ -124,7 +124,7 @@ static double allreduceSumDouble (double val)
static double totalMem() static double totalMem()
{ {
return mr::getProcessInfo("VmHWM")*1024; return ducc0::getProcessInfo("VmHWM")*1024;
} }
static size_t get_nalms(const sharp_alm_info &ainfo) static size_t get_nalms(const sharp_alm_info &ainfo)
...@@ -549,7 +549,7 @@ int main(int argc, const char **argv) ...@@ -549,7 +549,7 @@ int main(int argc, const char **argv)
{ {
string tmp2(tmp); string tmp2(tmp);
if (trim(tmp2)!="") if (trim(tmp2)!="")
mr::set_default_nthreads(stringToData<size_t>(tmp)); ducc0::set_default_nthreads(stringToData<size_t>(tmp));
} }
mytask=0; ntasks=1; mytask=0; ntasks=1;
......
...@@ -3,7 +3,7 @@ ...@@ -3,7 +3,7 @@
#include "ducc0/infra/error_handling.h" #include "ducc0/infra/error_handling.h"
using namespace std; using namespace std;
using namespace mr; using namespace ducc0;
namespace { namespace {
......
...@@ -17,7 +17,7 @@ ...@@ -17,7 +17,7 @@
#include "ducc0/infra/mav.h" #include "ducc0/infra/mav.h"
#include "ducc0/infra/error_handling.h" #include "ducc0/infra/error_handling.h"
namespace mr { namespace ducc0 {
namespace detail_alm { namespace detail_alm {
......
...@@ -20,7 +20,7 @@ ...@@ -20,7 +20,7 @@
#include "python/healpix.cc" #include "python/healpix.cc"
#include "python/misc.cc" #include "python/misc.cc"
using namespace mr; using namespace ducc0;
PYBIND11_MODULE(PKGNAME, m) PYBIND11_MODULE(PKGNAME, m)
{ {
......
...@@ -19,16 +19,16 @@ ...@@ -19,16 +19,16 @@
#include "ducc0/math/fft.h" #include "ducc0/math/fft.h"
#include "ducc0/bindings/pybind_utils.h" #include "ducc0/bindings/pybind_utils.h"
namespace mr { namespace ducc0 {
namespace detail_pymodule_fft { namespace detail_pymodule_fft {
namespace { namespace {
using shape_t = mr::fmav_info::shape_t; using shape_t = ducc0::fmav_info::shape_t;
using mr::fmav; using ducc0::fmav;
using mr::to_fmav; using ducc0::to_fmav;
using mr::get_optional_Pyarr; using ducc0::get_optional_Pyarr;
using std::size_t; using std::size_t;
using std::ptrdiff_t; using std::ptrdiff_t;
...@@ -106,7 +106,7 @@ template<typename T> py::array c2c_internal(const py::array &in, ...@@ -106,7 +106,7 @@ template<typename T> py::array c2c_internal(const py::array &in,
{ {
py::gil_scoped_release release; py::gil_scoped_release release;
T fct = norm_fct<T>(inorm, ain.shape(), axes); T fct = norm_fct<T>(inorm, ain.shape(), axes);
mr::c2c(ain, aout, axes, forward, fct, nthreads); ducc0::c2c(ain, aout, axes, forward, fct, nthreads);
} }
return move(out); return move(out);
} }
...@@ -122,9 +122,9 @@ template<typename T> py::array c2c_sym_internal(const py::array &in, ...@@ -122,9 +122,9 @@ template<typename T> py::array c2c_sym_internal(const py::array &in,
{ {
py::gil_scoped_release release; py::gil_scoped_release release;
T fct = norm_fct<T>(inorm, ain.shape(), axes); T fct = norm_fct<T>(inorm, ain.shape(), axes);
mr::r2c(ain, aout, axes, forward, fct, nthreads); ducc0::r2c(ain, aout, axes, forward, fct, nthreads);
// now fill in second half // now fill in second half
using namespace mr::detail_fft; using namespace ducc0::detail_fft;
rev_iter iter(aout, axes); rev_iter iter(aout, axes);
while(iter.remaining()>0) while(iter.remaining()>0)
{ {
...@@ -160,7 +160,7 @@ template<typename T> py::array r2c_internal(const py::array &in, ...@@ -160,7 +160,7 @@ template<typename T> py::array r2c_internal(const py::array &in,
{ {
py::gil_scoped_release release; py::gil_scoped_release release;
T fct = norm_fct<T>(inorm, ain.shape(), axes); T fct = norm_fct<T>(inorm, ain.shape(), axes);
mr::r2c(ain, aout, axes, forward, fct, nthreads); ducc0::r2c(ain, aout, axes, forward, fct, nthreads);
} }
return move(out); return move(out);
} }
...@@ -183,7 +183,7 @@ template<typename T> py::array r2r_fftpack_internal(const py::array &in, ...@@ -183,7 +183,7 @@ template<typename T> py::array r2r_fftpack_internal(const py::array &in,
{ {
py::gil_scoped_release release; py::gil_scoped_release release;
T fct = norm_fct<T>(inorm, ain.shape(), axes); T fct = norm_fct<T>(inorm, ain.shape(), axes);
mr::r2r_fftpack(ain, aout, axes, real2hermitian, forward, fct, nthreads); ducc0::r2r_fftpack(ain, aout, axes, real2hermitian, forward, fct, nthreads);
} }
return std::move(out); return std::move(out);
} }
...@@ -209,7 +209,7 @@ template<typename T> py::array dct_internal(const py::array &in, ...@@ -209,7 +209,7 @@ template<typename T> py::array dct_internal(const py::array &in,
T fct = (type==1) ? norm_fct<T>(inorm, ain.shape(), axes, 2, -1) T fct = (type==1) ? norm_fct<T>(inorm, ain.shape(), axes, 2, -1)
: norm_fct<T>(inorm, ain.shape(), axes, 2); : norm_fct<T>(inorm, ain.shape(), axes, 2);
bool ortho = inorm == true; bool ortho = inorm == true;
mr::dct(ain, aout, axes, type, fct, ortho, nthreads); ducc0::dct(ain, aout, axes, type, fct, ortho, nthreads);
} }
return std::move(out); return std::move(out);
} }
...@@ -235,7 +235,7 @@ template<typename T> py::array dst_internal(const py::array &in, ...@@ -235,7 +235,7 @@ template<typename T> py::array dst_internal(const py::array &in,
T fct = (type==1) ? norm_fct<T>(inorm, ain.shape(), axes, 2, 1) T fct = (type==1) ? norm_fct<T>(inorm, ain.shape(), axes, 2, 1)
: norm_fct<T>(inorm, ain.shape(), axes, 2); : norm_fct<T>(inorm, ain.shape(), axes, 2);
bool ortho = inorm == true; bool ortho = inorm == true;
mr::dst(ain, aout, axes, type, fct, ortho, nthreads); ducc0::dst(ain, aout, axes, type, fct, ortho, nthreads);
} }
return std::move(out); return std::move(out);
} }
...@@ -265,7 +265,7 @@ template<typename T> py::array c2r_internal(const py::array &in, ...@@ -265,7 +265,7 @@ template<typename T> py::array c2r_internal(const py::array &in,
{ {
py::gil_scoped_release release; py::gil_scoped_release release;
T fct = norm_fct<T>(inorm, aout.shape(), axes); T fct = norm_fct<T>(inorm, aout.shape(), axes);
mr::c2r(ain, aout, axes, forward, fct, nthreads); ducc0::c2r(ain, aout, axes, forward, fct, nthreads);
} }
return std::move(out); return std::move(out);
} }
...@@ -287,7 +287,7 @@ template<typename T> py::array separable_hartley_internal(const py::array &in, ...@@ -287,7 +287,7 @@ template<typename T> py::array separable_hartley_internal(const py::array &in,
{ {
py::gil_scoped_release release; py::gil_scoped_release release;
T fct = norm_fct<T>(inorm, ain.shape(), axes); T fct = norm_fct<T>(inorm, ain.shape(), axes);
mr::r2r_separable_hartley(ain, aout, axes, fct, nthreads); ducc0::r2r_separable_hartley(ain, aout, axes, fct, nthreads);
} }
return std::move(out); return std::move(out);
} }
...@@ -309,7 +309,7 @@ template<typename T> py::array genuine_hartley_internal(const py::array &in, ...@@ -309,7 +309,7 @@ template<typename T> py::array genuine_hartley_internal(const py::array &in,
{ {
py::gil_scoped_release release; py::gil_scoped_release release;
T fct = norm_fct<T>(inorm, ain.shape(), axes); T fct = norm_fct<T>(inorm, ain.shape(), axes);
mr::r2r_genuine_hartley(ain, aout, axes, fct, nthreads); ducc0::r2r_genuine_hartley(ain, aout, axes, fct, nthreads);
} }
return std::move(out); return std::move(out);
} }
...@@ -341,7 +341,7 @@ PyObject * good_size(PyObject * /*self*/, PyObject * args) ...@@ -341,7 +341,7 @@ PyObject * good_size(PyObject * /*self*/, PyObject * args)
return nullptr; return nullptr;
} }
const auto n = static_cast<size_t>(n_); const auto n = static_cast<size_t>(n_);
using namespace mr::detail_fft; using namespace ducc0::detail_fft;
return PyLong_FromSize_t( return PyLong_FromSize_t(
real ? util1d::good_size_real(n) : util1d::good_size_cmplx(n)); real ? util1d::good_size_real(n) : util1d::good_size_cmplx(n));
} }
......
...@@ -36,7 +36,7 @@ ...@@ -36,7 +36,7 @@
#include "ducc0/infra/mav.h" #include "ducc0/infra/mav.h"
#include "ducc0/math/es_kernel.h" #include "ducc0/math/es_kernel.h"
namespace mr { namespace ducc0 {
namespace detail_gridder { namespace detail_gridder {
...@@ -1121,6 +1121,6 @@ template<typename T> void dirty2ms(const mav<double,2> &uvw, ...@@ -1121,6 +1121,6 @@ template<typename T> void dirty2ms(const mav<double,2> &uvw,
using detail_gridder::ms2dirty; using detail_gridder::ms2dirty;
using detail_gridder::dirty2ms; using detail_gridder::dirty2ms;
} // namespace mr } // namespace ducc0
#endif #endif
...@@ -39,7 +39,7 @@ ...@@ -39,7 +39,7 @@
#include "ducc0/math/geom_utils.h" #include "ducc0/math/geom_utils.h"
#include "ducc0/bindings/pybind_utils.h" #include "ducc0/bindings/pybind_utils.h"
namespace mr { namespace ducc0 {
namespace detail_pymodule_healpix { namespace detail_pymodule_healpix {
......
...@@ -37,7 +37,7 @@ ...@@ -37,7 +37,7 @@
#include "ducc0/bindings/pybind_utils.h" #include "ducc0/bindings/pybind_utils.h"
#include "python/alm.h" #include "python/alm.h"
namespace mr { namespace ducc0 {
namespace detail_pymodule_misc { namespace detail_pymodule_misc {
......
...@@ -38,7 +38,7 @@ ...@@ -38,7 +38,7 @@
#include "ducc0/math/constants.h" #include "ducc0/math/constants.h"
#include "ducc0/bindings/pybind_utils.h" #include "ducc0/bindings/pybind_utils.h"
namespace mr { namespace ducc0 {
namespace detail_pymodule_sht { namespace detail_pymodule_sht {
......
...@@ -7,7 +7,7 @@ ...@@ -7,7 +7,7 @@
#include <pybind11/numpy.h> #include <pybind11/numpy.h>
#include "python/totalconvolve.h" #include "python/totalconvolve.h"
namespace mr { namespace ducc0 {
namespace detail_pymodule_totalconvolve { namespace detail_pymodule_totalconvolve {
......
...@@ -23,7 +23,7 @@ ...@@ -23,7 +23,7 @@
#include "python/alm.h" #include "python/alm.h"
#include "ducc0/math/fft.h" #include "ducc0/math/fft.h"
namespace mr { namespace ducc0 {
namespace detail_fft { namespace detail_fft {
......
...@@ -24,7 +24,7 @@ ...@@ -24,7 +24,7 @@
#include "ducc0/bindings/pybind_utils.h" #include "ducc0/bindings/pybind_utils.h"
#include "python/gridder_cxx.h" #include "python/gridder_cxx.h"
namespace mr { namespace ducc0 {
namespace detail_pymodule_wgridder { namespace detail_pymodule_wgridder {
......
...@@ -6,7 +6,7 @@ ...@@ -6,7 +6,7 @@
#include "ducc0/infra/mav.h" #include "ducc0/infra/mav.h"
namespace mr { namespace ducc0 {
namespace detail_pybind { namespace detail_pybind {
......
...@@ -35,7 +35,7 @@ ...@@ -35,7 +35,7 @@
#include "ducc0/infra/mav.h" #include "ducc0/infra/mav.h"
#include "ducc0/math/space_filling.h" #include "ducc0/math/space_filling.h"
namespace mr { namespace ducc0 {
namespace detail_healpix { namespace detail_healpix {
......
...@@ -37,7 +37,7 @@ ...@@ -37,7 +37,7 @@
#include "ducc0/math/pointing.h" #include "ducc0/math/pointing.h"
#include "ducc0/math/rangeset.h" #include "ducc0/math/rangeset.h"
namespace mr { namespace ducc0 {
namespace detail_healpix { namespace detail_healpix {
......
...@@ -33,7 +33,7 @@ ...@@ -33,7 +33,7 @@
#include "ducc0/infra/string_utils.h" #include "ducc0/infra/string_utils.h"
#include "ducc0/infra/error_handling.h" #include "ducc0/infra/error_handling.h"
namespace mr { namespace ducc0 {
namespace detail_healpix { namespace detail_healpix {
......
...@@ -35,7 +35,7 @@ ...@@ -35,7 +35,7 @@
#include <cstdint> #include <cstdint>
#include <string> #include <string>
namespace mr { namespace ducc0 {
namespace detail_healpix { namespace detail_healpix {
......
...@@ -25,7 +25,7 @@ ...@@ -25,7 +25,7 @@
#include <cstdlib> #include <cstdlib>
#include <memory> #include <memory>
namespace mr { namespace ducc0 {
namespace detail_aligned_array { namespace detail_aligned_array {
......
...@@ -5,7 +5,7 @@ ...@@ -5,7 +5,7 @@
#include "ducc0/infra/communication.h" #include "ducc0/infra/communication.h"
#include "ducc0/infra/error_handling.h" #include "ducc0/infra/error_handling.h"
namespace mr { namespace ducc0 {
namespace detail_communication { namespace detail_communication {
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment