Giter Site home page Giter Site logo

Comments (3)

sdmiller avatar sdmiller commented on July 30, 2024 1

Hi @hitsjt ,

So the getFrustumCulledVoxels function is simply trying to minimize wasted time. Since we know the focal parameters and location of the camera, we know which voxels are not in its field of view. This means we can "cull" (i.e. trim down) only to the voxels we actually will need to update.

When we deal with poses, we tend to use what I'd call "Computer Vision" coordinates: X is right, Y is down, Z is forward. The PCL class we use for computing the view frustum, pcl::FrustumCulling, seems to use what I'd call "Robotics" coordinates, flipping X and Z and negating Y. This is just a coordinate transform from one arbitrary system to another:

Eigen::Matrix4f trans_robot = trans.matrix ().cast () * cam2robot;

from cpu_tsdf.

sdmiller avatar sdmiller commented on July 30, 2024 1

@hitsjt sorry! This is why I shouldn't have turned github alerts off :(.

I'm guessing by now your questions are no longer relevant, but for posterity:

  • Yes, I transform the voxel center to the current frame and reproject it to get a new observation
  • This new "distance" is the new observation of d, where d is "how far, in the Z dimension, is the point from the voxel center?" If the point had been exactly at the voxel center, this would be an observation of 0, or a perfect reading of the surface.
  • My split-checking is all something I came up with, to try to make these things fit in memory. I keep big voxels and only iteratively make them smaller as needed. So if a point falls within a voxel, I check to see if I need to split it, then recursively check each split voxel for their own readings.
  • The coordinates are a bit arbitrary, just things I happened to notice work well for walking around a room with a Kinect. The camera is always at the origin (0,0,0) for me when I begin, but of course, you input that yourself whenever you call integrateCloud(). In general people record things by standing a bit away and pointing. So assuming it was about 2 meters in front of the camera seemed to work well.

from cpu_tsdf.

hitsjt avatar hitsjt commented on July 30, 2024

Thank you sdmiller!
I still have more questions.

  • In function
    template <typename PointT, typename NormalT> int cpu_tsdf::TSDFVolumeOctree::updateVoxel ( const cpu_tsdf::OctreeNode::Ptr &voxel, const pcl::PointCloud<PointT> &cloud, const pcl::PointCloud<NormalT> &normals, const Eigen::Affine3f &trans_inv),
    • you transformed voxel center to current frame,and reproject it to get the current observation,am i right?
    • Then you do float d_new = (pt.z - v_g.z);to get the new distance,why is that?
    • and then what is the purpose of checking split in the following code?
  • Question about the coordinates
    If i am not wrong ,you put the whole volume center at (2,2,2),but where is the cam?

Thank you!

from cpu_tsdf.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.