LSST Applications g070148d5b3+33e5256705,g0d53e28543+25c8b88941,g0da5cf3356+2dd1178308,g1081da9e2a+62d12e78cb,g17e5ecfddb+7e422d6136,g1c76d35bf8+ede3a706f7,g295839609d+225697d880,g2e2c1a68ba+cc1f6f037e,g2ffcdf413f+853cd4dcde,g38293774b4+62d12e78cb,g3b44f30a73+d953f1ac34,g48ccf36440+885b902d19,g4b2f1765b6+7dedbde6d2,g5320a0a9f6+0c5d6105b6,g56b687f8c9+ede3a706f7,g5c4744a4d9+ef6ac23297,g5ffd174ac0+0c5d6105b6,g6075d09f38+66af417445,g667d525e37+2ced63db88,g670421136f+2ced63db88,g71f27ac40c+2ced63db88,g774830318a+463cbe8d1f,g7876bc68e5+1d137996f1,g7985c39107+62d12e78cb,g7fdac2220c+0fd8241c05,g96f01af41f+368e6903a7,g9ca82378b8+2ced63db88,g9d27549199+ef6ac23297,gabe93b2c52+e3573e3735,gb065e2a02a+3dfbe639da,gbc3249ced9+0c5d6105b6,gbec6a3398f+0c5d6105b6,gc9534b9d65+35b9f25267,gd01420fc67+0c5d6105b6,geee7ff78d7+a14128c129,gf63283c776+ede3a706f7,gfed783d017+0c5d6105b6,w.2022.47
LSST Data Management Base Package
|
Namespaces | |
namespace | backtrace |
namespace | python |
namespace | version |
Classes | |
class | Backtrace |
Singleton, enables automatic backtraces on the following signals: More... | |
class | Cache |
Cache of most recently used values. More... | |
struct | key |
struct | n |
class | Symbol |
Functions | |
std::string | demangleType (std::string const _typeName) |
std::size_t | hashCombine (std::size_t seed) noexcept |
Combine hashes. More... | |
template<typename T , typename... Rest> | |
std::size_t | hashCombine (std::size_t seed, const T &value, Rest... rest) noexcept |
Combine hashes. More... | |
template<typename InputIterator > | |
std::size_t | hashIterable (std::size_t seed, InputIterator begin, InputIterator end) noexcept |
Combine hashes in an iterable. More... | |
double | nanojanskyToABMagnitude (double flux) |
Convert a flux in nanojansky to AB magnitude. More... | |
double | ABMagnitudeToNanojansky (double magnitude) |
Convert an AB magnitude to a flux in nanojansky. More... | |
std::string | getPackageDir (std::string const &packageName) |
return the root directory of a setup package More... | |
template<typename T > | |
constexpr void | assertValidHash () |
Compile-time test of whether a specialization of std::hash conforms to the general spec. More... | |
template<typename T > | |
void | assertHashesEqual (T obj1, T obj2) |
Test that equal objects have equal hashes. More... | |
void | wrapBacktrace (python::WrapperCollection &wrappers) |
void | wrapDemangle (python::WrapperCollection &wrappers) |
PYBIND11_MODULE (_cpputils, mod) | |
Variables | |
const double | referenceFlux = 1e23 * pow(10, (48.6 / -2.5)) * 1e9 |
The Oke & Gunn (1983) AB magnitude reference flux, in nJy (often approximated as 3631.0). More... | |
double lsst::cpputils::ABMagnitudeToNanojansky | ( | double | magnitude | ) |
Convert an AB magnitude to a flux in nanojansky.
Definition at line 32 of file Magnitude.cc.
void lsst::cpputils::assertHashesEqual | ( | T | obj1, |
T | obj2 | ||
) |
Test that equal objects have equal hashes.
If objects of type T
can be equal despite having different internal representations, you should include pairs of such objects.
T | A hashable type. |
obj1,obj2 | Two equal objects. |
Definition at line 102 of file tests.h.
|
constexpr |
Compile-time test of whether a specialization of std::hash conforms to the general spec.
The function itself is a no-op.
T | The properties of std::hash<T> will be tested. |
Definition at line 72 of file tests.h.
std::string lsst::cpputils::demangleType | ( | std::string const | _typeName | ) |
Definition at line 113 of file Demangle.cc.
std::string lsst::cpputils::getPackageDir | ( | std::string const & | packageName | ) |
return the root directory of a setup package
[in] | packageName | name of package (e.g. "utils") |
lsst::pex::exceptions::NotFoundError | if desired version can't be found |
Definition at line 33 of file packaging.cc.
|
inlinenoexcept |
Combine hashes.
A specialization of hashCombine for a trivial argument list.
Definition at line 35 of file hashCombine.h.
|
noexcept |
Combine hashes.
This is provided as a convenience for those who need to hash a composite. C++11 includes std::hash, but neglects to include a facility for combining hashes.
T,Rest | the types to hash. All types must have a valid (in particular, non-throwing) specialization of std::hash. |
seed | An arbitrary starting value. |
value,rest | The objects to hash. |
seed
.To use it:
// Arbitrary seed; can change to get different hashes of same argument list std::size_t seed = 0; result = hashCombine(seed, obj1, obj2, obj3);
Definition at line 63 of file hashCombine.h.
|
noexcept |
Combine hashes in an iterable.
This is provided as a convenience for those who need to hash a container.
InputIterator | an iterator to the objects to be hashed. The pointed-to type must have a valid (in particular, non-throwing) specialization of std::hash. |
seed | An arbitrary starting value. |
begin,end | The range to hash. |
To use it:
// Arbitrary seed; can change to get different hashes of same argument list std::size_t seed = 0; result = hashIterable(seed, container.begin(), container.end());
Definition at line 93 of file hashCombine.h.
double lsst::cpputils::nanojanskyToABMagnitude | ( | double | flux | ) |
Convert a flux in nanojansky to AB magnitude.
Definition at line 30 of file Magnitude.cc.
lsst::cpputils::PYBIND11_MODULE | ( | _cpputils | , |
mod | |||
) |
Definition at line 32 of file _cpputils.cc.
void lsst::cpputils::wrapBacktrace | ( | python::WrapperCollection & | wrappers | ) |
Definition at line 32 of file _Backtrace.cc.
void lsst::cpputils::wrapDemangle | ( | python::WrapperCollection & | wrappers | ) |
Definition at line 32 of file _Demangle.cc.
const double lsst::cpputils::referenceFlux = 1e23 * pow(10, (48.6 / -2.5)) * 1e9 |
The Oke & Gunn (1983) AB magnitude reference flux, in nJy (often approximated as 3631.0).
Definition at line 46 of file Magnitude.h.