|
DNDSR 0.1.0.dev1+gcd065ad
Distributed Numeric Data Structure for CFV
|
Eigen extensions: to_string, an fmt-safe wrapper, and fmt formatter specialisations for dense Eigen matrices.
More...
#include "EigenPCH.hpp"#include "Defines.hpp"#include <fmt/core.h>#include <fmt/ostream.h>#include <fmt/format.h>#include "DeviceStorage.hpp"#include "Vector.hpp"Go to the source code of this file.
Classes | |
| struct | Eigen::MatrixFMTSafe< T, M, N, options, max_m, max_n > |
Eigen::Matrix wrapper that hides begin/end from fmt. More... | |
| struct | DNDS::Meta::is_real_eigen_fmt_safe_matrix< T > |
Type trait: is T a MatrixFMTSafe with real scalar? Used by the fmt formatter below to catch both wrapped and unwrapped Eigen types. More... | |
| struct | DNDS::Meta::is_real_eigen_fmt_safe_matrix< Eigen::MatrixFMTSafe< real, M, N, options, max_m, max_n > > |
| struct | fmt::formatter< T, Char, std::enable_if_t< DNDS::Meta::is_eigen_dense_v< std::remove_cv_t< T > >||DNDS::Meta::is_real_eigen_fmt_safe_matrix_v< std::remove_cv_t< T > > > > |
| class | DNDS::EigenMatrixView< B, t_scalar, M, N > |
| class | DNDS::HostDeviceEigenMatrix< t_scalar, M, N > |
Namespaces | |
| namespace | DNDS |
| the host side operators are provided as implemented | |
| namespace | Eigen |
| namespace | DNDS::Meta |
Typedefs | |
| template<class T , int M> | |
| using | Eigen::VectorFMTSafe = MatrixFMTSafe< T, M, 1 > |
| Column-vector alias of MatrixFMTSafe. | |
| template<class T , int N> | |
| using | Eigen::RowVectorFMTSafe = MatrixFMTSafe< T, 1, N > |
| Row-vector alias of MatrixFMTSafe. | |
Functions | |
| template<class dir > | |
| std::string | DNDS::to_string (const Eigen::DenseBase< dir > &v, int precision=5, bool scientific=false) |
Render an Eigen::DenseBase to a string via operator<<. | |
Variables | |
| template<class T > | |
| constexpr bool | DNDS::Meta::is_real_eigen_fmt_safe_matrix_v = is_real_eigen_fmt_safe_matrix<T>::value |
| const bool | DNDS::Meta::v = is_real_eigen_fmt_safe_matrix_v<Eigen::MatrixFMTSafe<real, 3, 3>> |
Eigen extensions: to_string, an fmt-safe wrapper, and fmt formatter specialisations for dense Eigen matrices.
The MatrixFMTSafe / VectorFMTSafe helpers exist because modern fmtlib (with fmt/ranges.h) will detect Eigen::Matrix as a range and format it as [a, b, c, ...], overriding the Eigen stream formatting that DNDSR wants. Wrapping Eigen types with these aliases hides the iterator interface from fmt and keeps the matrix pretty-print.
Definition in file EigenUtil.hpp.