Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Evaluation #5

Merged
merged 11 commits into from Oct 4, 2021
Merged

Evaluation #5

merged 11 commits into from Oct 4, 2021

Conversation

eduardramon
Copy link
Contributor

@eduardramon eduardramon commented Oct 4, 2021

This PRs easies the evaluation process, which is now reduced to a single line of code:

mesh_gt, images, masks, cameras = h3ds.load_scene(scene_id)
mesh_pred, landmarks_pred = your_reconstruction_method(images, masks, cameras)
chamfer_gt_pred, chamfer_pred_gt, mesh_gt, mesh_pred_aligned =  h3ds.evaluate_scene(scene_id, mesh_pred, landmarks_pred)

The PR includes the following changes:

  • The evaluation method evaluate_scene. It performs a coarse_alignment using the provided landmarks (optional), a fine alignment using ICP, and computes the chamfer distance (CD) in both directions. If a region_id is provided, the ICP is used only using this region and the CDs are computed only in this region as well.
  •  Now meshes are handled with an internal Mesh class to avoid. This avoids the reordering in the vertices observed using Trimesh.
  • Methods for aligning meshes (coarse and ICP) and for transforming them.
  •  A method error_to_color to easily compute heatmaps.
  •  An update of the examples/evaluation.py script.
  •  An image showing the position of each landmark.
  • An update of the README.md documentation.

Copy link
Contributor

@albertorb albertorb left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👏🏿 🚀

Copy link
Collaborator

@a-canela a-canela left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👌🏽 👌🏽

h3ds/dataset.py Outdated
def load_landmarks(self, scene_id: str):
"""
Loads the landmarks for a given scene as dictionary. The landmark
is provided with a point identifier of the scene mesh vertices
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

point identifier -> point index

@eduardramon eduardramon merged commit 4a15bc2 into main Oct 4, 2021
@eduardramon eduardramon deleted the evaluation branch October 4, 2021 09:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants