View Source Evision.PPFMatch3D (Evision v0.1.28)

Link to this section Summary

Types

t()

Type that represents an PPFMatch3D struct.

Functions

Compute the normals of an arbitrary point cloud computeNormalsPC3d uses a plane fitting approach to smoothly compute local normals. Normals are obtained through the eigenvector of the covariance matrix, corresponding to the smallest eigen value. If PCNormals is provided to be an Nx6 matrix, then no new allocation is made, instead the existing memory is overwritten.

Compute the normals of an arbitrary point cloud computeNormalsPC3d uses a plane fitting approach to smoothly compute local normals. Normals are obtained through the eigenvector of the covariance matrix, corresponding to the smallest eigen value. If PCNormals is provided to be an Nx6 matrix, then no new allocation is made, instead the existing memory is overwritten.

getRandomPose

Load a PLY file

transformPCPose

Write a point cloud to PLY file

Used for debbuging pruposes, writes a point cloud to a PLY file with the tip of the normal vectors as visible red points

Link to this section Types

@type t() :: %Evision.PPFMatch3D{ref: reference()}

Type that represents an PPFMatch3D struct.

  • ref. reference()

    The underlying erlang resource variable.

Link to this section Functions

@spec addNoisePC(Evision.Mat.maybe_mat_in(), number()) ::
  Evision.Mat.t() | {:error, String.t()}

addNoisePC

Positional Arguments
  • pc: Evision.Mat.t()
  • scale: double
Return
  • retval: Evision.Mat.t()

    Adds a uniform noise in the given scale to the input point cloud

Python prototype (for reference only):

addNoisePC(pc, scale) -> retval
Link to this function

computeNormalsPC3d(pC, numNeighbors, flipViewpoint, viewpoint)

View Source
@spec computeNormalsPC3d(
  Evision.Mat.maybe_mat_in(),
  integer(),
  boolean(),
  {number(), number(), number()}
) :: {integer(), Evision.Mat.t()} | {:error, String.t()}

Compute the normals of an arbitrary point cloud computeNormalsPC3d uses a plane fitting approach to smoothly compute local normals. Normals are obtained through the eigenvector of the covariance matrix, corresponding to the smallest eigen value. If PCNormals is provided to be an Nx6 matrix, then no new allocation is made, instead the existing memory is overwritten.

Positional Arguments
  • pC: Evision.Mat.t()
  • numNeighbors: int
  • flipViewpoint: bool
  • viewpoint: Vec3f
Return
  • retval: int
  • pCNormals: Evision.Mat.t().

@return Returns 0 on success

Python prototype (for reference only):

computeNormalsPC3d(PC, NumNeighbors, FlipViewpoint, viewpoint[, PCNormals]) -> retval, PCNormals
Link to this function

computeNormalsPC3d(pC, numNeighbors, flipViewpoint, viewpoint, opts)

View Source
@spec computeNormalsPC3d(
  Evision.Mat.maybe_mat_in(),
  integer(),
  boolean(),
  {number(), number(), number()},
  [{atom(), term()}, ...] | nil
) :: {integer(), Evision.Mat.t()} | {:error, String.t()}

Compute the normals of an arbitrary point cloud computeNormalsPC3d uses a plane fitting approach to smoothly compute local normals. Normals are obtained through the eigenvector of the covariance matrix, corresponding to the smallest eigen value. If PCNormals is provided to be an Nx6 matrix, then no new allocation is made, instead the existing memory is overwritten.

Positional Arguments
  • pC: Evision.Mat.t()
  • numNeighbors: int
  • flipViewpoint: bool
  • viewpoint: Vec3f
Return
  • retval: int
  • pCNormals: Evision.Mat.t().

@return Returns 0 on success

Python prototype (for reference only):

computeNormalsPC3d(PC, NumNeighbors, FlipViewpoint, viewpoint[, PCNormals]) -> retval, PCNormals
@spec getRandomPose(Evision.Mat.t()) :: :ok | {:error, String.t()}

getRandomPose

Positional Arguments
  • pose: Evision.Mat.t()

    Generate a random 4x4 pose matrix

Python prototype (for reference only):

getRandomPose(Pose) -> None
@spec loadPLYSimple(binary()) :: Evision.Mat.t() | {:error, String.t()}

Load a PLY file

Positional Arguments
  • fileName: c_string
Keyword Arguments
  • withNormals: int.
Return
  • retval: Evision.Mat.t()

@return Returns the matrix on successful load

Python prototype (for reference only):

loadPLYSimple(fileName[, withNormals]) -> retval
Link to this function

loadPLYSimple(fileName, opts)

View Source
@spec loadPLYSimple(binary(), [{atom(), term()}, ...] | nil) ::
  Evision.Mat.t() | {:error, String.t()}

Load a PLY file

Positional Arguments
  • fileName: c_string
Keyword Arguments
  • withNormals: int.
Return
  • retval: Evision.Mat.t()

@return Returns the matrix on successful load

Python prototype (for reference only):

loadPLYSimple(fileName[, withNormals]) -> retval
Link to this function

samplePCByQuantization(pc, xrange, yrange, zrange, sample_step_relative)

View Source
@spec samplePCByQuantization(
  Evision.Mat.maybe_mat_in(),
  {number(), number()},
  {number(), number()},
  {number(), number()},
  number()
) :: Evision.Mat.t() | {:error, String.t()}

samplePCByQuantization

Positional Arguments
  • pc: Evision.Mat.t()
  • xrange: Vec2f
  • yrange: Vec2f
  • zrange: Vec2f
  • sample_step_relative: float
Keyword Arguments
  • weightByCenter: int.
Return
  • retval: Evision.Mat.t()

    Sample a point cloud using uniform steps

@return Sampled point cloud

Python prototype (for reference only):

samplePCByQuantization(pc, xrange, yrange, zrange, sample_step_relative[, weightByCenter]) -> retval
Link to this function

samplePCByQuantization(pc, xrange, yrange, zrange, sample_step_relative, opts)

View Source
@spec samplePCByQuantization(
  Evision.Mat.maybe_mat_in(),
  {number(), number()},
  {number(), number()},
  {number(), number()},
  number(),
  [{atom(), term()}, ...] | nil
) :: Evision.Mat.t() | {:error, String.t()}

samplePCByQuantization

Positional Arguments
  • pc: Evision.Mat.t()
  • xrange: Vec2f
  • yrange: Vec2f
  • zrange: Vec2f
  • sample_step_relative: float
Keyword Arguments
  • weightByCenter: int.
Return
  • retval: Evision.Mat.t()

    Sample a point cloud using uniform steps

@return Sampled point cloud

Python prototype (for reference only):

samplePCByQuantization(pc, xrange, yrange, zrange, sample_step_relative[, weightByCenter]) -> retval
Link to this function

transformPCPose(pc, pose)

View Source
@spec transformPCPose(Evision.Mat.maybe_mat_in(), Evision.Mat.t()) ::
  Evision.Mat.t() | {:error, String.t()}

transformPCPose

Positional Arguments
  • pc: Evision.Mat.t()
  • pose: Evision.Mat.t()
Return
  • retval: Evision.Mat.t()

    Transforms the point cloud with a given a homogeneous 4x4 pose matrix (in double precision)

@return Transformed point cloud

Python prototype (for reference only):

transformPCPose(pc, Pose) -> retval
@spec writePLY(Evision.Mat.maybe_mat_in(), binary()) :: :ok | {:error, String.t()}

Write a point cloud to PLY file

Positional Arguments
  • pC: Evision.Mat.t()
  • fileName: c_string

Python prototype (for reference only):

writePLY(PC, fileName) -> None
Link to this function

writePLYVisibleNormals(pC, fileName)

View Source
@spec writePLYVisibleNormals(Evision.Mat.maybe_mat_in(), binary()) ::
  :ok | {:error, String.t()}

Used for debbuging pruposes, writes a point cloud to a PLY file with the tip of the normal vectors as visible red points

Positional Arguments
  • pC: Evision.Mat.t()
  • fileName: c_string

Python prototype (for reference only):

writePLYVisibleNormals(PC, fileName) -> None