24#ifndef INV_RAP_MUSIC_H
25#define INV_RAP_MUSIC_H
94 typedef QSharedPointer<InvRapMusic>
SPtr;
95 typedef QSharedPointer<const InvRapMusic>
ConstSPtr;
102 typedef Eigen::Matrix<double, Eigen::Dynamic, Eigen::Dynamic>
MatrixXT;
104 typedef Eigen::Matrix<double, Eigen::Dynamic, 6>
MatrixX6T;
106 typedef Eigen::Matrix<double, 6, Eigen::Dynamic>
Matrix6XT;
110 typedef Eigen::Matrix<double, Eigen::Dynamic, 1>
VectorXT;
154 virtual const char*
getName()
const;
165 void setStcAttr(
int p_iSampStcWin,
float p_fStcOverlap);
248 const int p_iNumCombinations,
249 std::vector<Pair>& p_pairIdxCombinations)
const;
267 static void getPointPair(
const int p_iPoints,
const int p_iCurIdx,
int& p_iIdx1,
int& p_iIdx2);
280 int p_iIdx1,
int p_iIdx2);
292 static void insertSource(
int p_iDipoleIdx1,
int p_iDipoleIdx2,
364 for (t_iRank = p_matSigma.rows() - 1; t_iRank > 0; t_iRank--)
365 if (p_matSigma(t_iRank, t_iRank) > 0.00001)
380 int rank =
getRank(p_matSigma_src);
383 p_matFull_Rank = p_Mat.block(0, 0, p_Mat.rows(), rank);
385 p_matFull_Rank = p_Mat.block(0, 0, rank, p_Mat.cols());
Templated dipole and dipole-pair value types used by the RAP-MUSIC scanning algorithm.
INVLIB library export/import macros, build-info accessors, and namespace docstring for the inverse-so...
InvSourceEstimate value type — central source-space data container produced by every INVLIB inverse s...
Forward solution (gain matrix mapping source dipoles to sensor measurements).
Inverse source estimation (MNE, dSPM, sLORETA, dipole fitting).
constexpr auto NOT_TRANSPOSED
constexpr auto IS_TRANSPOSED
Single averaged evoked response: time axis, data, baseline, channel info and averaging metadata.
Source-space inverse-solution container with dense grid plus optional focal-dipole,...
Pair of correlated dipole indices and orientations found by the RAP MUSIC scanning step.
Index pair representing two grid points evaluated together in the RAP MUSIC subspace scan.
Eigen::Matrix< double, 6, 1 > Vector6T
void calcPairCombinations(const int p_iNumPoints, const int p_iNumCombinations, std::vector< Pair > &p_pairIdxCombinations) const
static void calcA_k_1(const MatrixX6T &p_matG_k_1, const Vector6T &p_matPhi_k_1, const int p_iIdxk_1, MatrixXT &p_matA_k_1)
static void getPointPair(const int p_iPoints, const int p_iCurIdx, int &p_iIdx1, int &p_iIdx2)
virtual InvSourceEstimate calculateInverse(const FIFFLIB::FiffEvoked &p_fiffEvoked, bool pick_normal=false)
static int getRank(const MatrixXT &p_matSigma)
virtual const char * getName() const
static MatrixXT makeSquareMat(const MatrixXT &p_matF)
static void insertSource(int p_iDipoleIdx1, int p_iDipoleIdx2, const Vector6T &p_vec_phi_k_1, double p_valCor, QList< InvDipolePair< double > > &p_RapDipoles)
void setStcAttr(int p_iSampStcWin, float p_fStcOverlap)
bool init(MNELIB::MNEForwardSolution &p_pFwd, bool p_bSparsed=false, int p_iN=2, double p_dThr=0.5)
Eigen::Matrix< double, Eigen::Dynamic, Eigen::Dynamic > MatrixXT
Eigen::Matrix< double, 6, 6 > Matrix6T
Eigen::Matrix< double, Eigen::Dynamic, 1 > VectorXT
QSharedPointer< InvRapMusic > SPtr
virtual InvSourceEstimate calculateInverse(const Eigen::MatrixXd &p_matMeasurement, QList< InvDipolePair< double > > &p_RapDipoles) const
void calcOrthProj(const MatrixXT &p_matA_k_1, MatrixXT &p_matOrthProj) const
static int useFullRank(const MatrixXT &p_Mat, const MatrixXT &p_matSigma_src, MatrixXT &p_matFull_Rank, int type=NOT_TRANSPOSED)
int calcPhi_s(const MatrixXT &p_matMeasurement, MatrixXT &p_matPhi_s) const
Eigen::Matrix< double, Eigen::Dynamic, 6 > MatrixX6T
MNELIB::MNEForwardSolution m_ForwardSolution
virtual const MNELIB::MNESourceSpaces & getSourceSpace() const
std::vector< Pair > m_ppPairIdxCombinations
Eigen::Matrix< double, 6, Eigen::Dynamic > Matrix6XT
virtual InvSourceEstimate calculateInverse(const Eigen::MatrixXd &data, float tmin, float tstep, bool pick_normal=false) const
static void getGainMatrixPair(const MatrixXT &p_matGainMarix, MatrixX6T &p_matGainMarix_Pair, int p_iIdx1, int p_iIdx2)
int m_iNumLeadFieldCombinations
static double subcorr(MatrixX6T &p_matProj_G, const MatrixXT &p_pMatU_B)
QSharedPointer< const InvRapMusic > ConstSPtr
In-memory representation of an -fwd.fif forward solution.
List of MNESourceSpace objects forming a subject source space.