Conversation
…d ignored error output for pr
…rom a float to a double you don't lose any data but whatever)
…ike switching between double and float so loosely during compilation
j4lando
reviewed
Mar 8, 2026
| int pointsSize = p.size(); | ||
| Eigen::Matrix<decimal, Eigen::Dynamic, 4> normalizedVecsToHorizonMat; | ||
| for (int i = 0; i < pointsSize; i++) { | ||
| Vec3 pBar = {p[i].x(), p[i].y(), 1}; |
Contributor
There was a problem hiding this comment.
try using pixelToImageCoordinates
j4lando
reviewed
Mar 8, 2026
| for (int i = 0; i < pointsSize; i++) { | ||
| Vec3 pBar = {p[i].x(), p[i].y(), 1}; | ||
| Vec3 normalizedVecToHorizon = (imageToSpace * pBar).normalized(); | ||
| for (int j = 0; j < 3; j++){ |
Contributor
There was a problem hiding this comment.
try using Eigen's built in arrays
#include <iostream>
#include <Eigen/Dense>
#include <vector>
int main() {
int n = 5; // Number of vectors
// 1. Initialize a 3xn matrix (3 rows, Dynamic columns)
Eigen::Matrix3Xd matrix = Eigen::Matrix3Xd::Zero(3, n);
// 2. Loop to add 3D vectors
for (int i = 0; i < n; ++i) {
// Create a temporary 3D vector
Eigen::Vector3d vec(i, i * 2.0, i * 3.0);
// Assign the vector to the i-th column
matrix.col(i) = vec;
}
std::cout << "Populated Matrix:\n" << matrix << std::endl;
return 0;
}
j4lando
reviewed
Mar 8, 2026
| Mat3 imageToSpace = DiagInvAxes * TPC_.transpose() * cam_.GetInverseCalibrationMatrix(); | ||
|
|
||
| int pointsSize = p.size(); | ||
| Eigen::Matrix<decimal, Eigen::Dynamic, 4> normalizedVecsToHorizonMat; |
Contributor
There was a problem hiding this comment.
don't use dynamic we know the size it is p.size()
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
A straightforward CRA implementation that assumes TLS and Eigen (the one with camera stuff) have been merged to main
Artifacts for PR #69 (DO NOT CHANGE)