31 #include <l/l_word_list.h>
32 #include <l/l_sys_io.h>
34 #ifdef KJB_HAVE_UA_CARTWHEEL
35 #include <MathLib/Point3d.h>
36 #include <MathLib/Vector3d.h>
37 #include <Core/Visualization.h>
47 #ifdef KJB_HAVE_UA_CARTWHEEL
48 inline kjb::Vector to_kjb(
const CartWheel::Math::Point3d& pt)
53 inline kjb::Vector to_kjb(
const CartWheel::Math::Vector3d& vec)
60 CartWheel::Math::Vector3d imag = q.getV();
61 double real = q.getS();
66 #ifdef KJB_HAVE_UA_CARTWHEEL
67 inline CartWheel::Math::Point3d to_cw_pt_3d(
const kjb::Vector& pt)
69 assert(pt.
size() == 3);
70 return CartWheel::Math::Point3d(pt[0], pt[1], pt[2]);
75 #ifdef KJB_HAVE_UA_CARTWHEEL
76 inline CartWheel::Math::Vector3d to_cw_vec_3d(
const kjb::Vector& vec)
78 assert(vec.
size() == 3);
79 return CartWheel::Math::Vector3d(vec[0], vec[1], vec[2]);
84 #ifdef KJB_HAVE_UA_CARTWHEEL
91 void set_camera(CartWheel::Visualization& vis,
const kjb::Perspective_camera& cam,
double WIDTH,
double HEIGHT);
115 using namespace geometry;
137 std::vector<Deva_detection>& deva_boxes,
139 double screen_height,
141 double avereage_height
Simulator_type
Definition: psi_util.h:122
virtual void set_camera_centre(const kjb::Vector &icentre)
sets the camera centre
Definition: perspective_camera.cpp:695
std::ostream & operator<<(std::ostream &ost, const Action &action)
serialize an action
Definition: psi_action.cpp:333
size_type size() const
Alias to get_length(). Required to comply with stl Container concept.
Definition: m_vector.h:510
Class that represents an axis-aligned 2D rectangle. It is defined in terms of its (2D) center...
Definition: gr_2D_bounding_box.h:51
Definition: psi_util.h:122
std::istream & operator>>(std::istream &ist, Action &action)
unserialize an action
Definition: psi_action.cpp:346
virtual void set_focal_length(double ifocal)
sets the focal length
Definition: perspective_camera.cpp:872
Vector project_and_unstandarize(const Vector &x, const Matrix &P, double w, double h)
Project the 3D point x to image coordinate using camera matrix P and make the top left as the origin...
Definition: psi_util.h:113
height
Definition: APPgetLargeConnectedEdges.m:33
This class implements vectors, in the linear-algebra sense, with real-valued elements.
Definition: m_vector.h:87
Definition: g_quaternion.h:79
Definition: d_deva_detection.h:41
Vector projective_to_euclidean_2d(const Vector &v)
Converts coordinates in (2D) projective space to coordinates in (2D) euclidean space.
Definition: g_util.cpp:109
St_perspective_camera for modeling a perspective camera using the classic Forsyth and Ponce parametri...
Definition: psi_util.h:122
Definition: g_quaternion.h:40
Definition: perspective_camera.h:93
x
Definition: APPgetLargeConnectedEdges.m:100
Vector euclidean_to_projective(const Vector &v)
Converts coordinates in euclidean space to coordinates in projective space.
Definition: g_util.cpp:122
const std::string & get_name(Action_type t)
Convert Action_type to string.
Definition: psi_action.cpp:198
x2
Definition: APPgetLargeConnectedEdges.m:123
void prune_by_height(std::vector< Deva_detection > &deva_boxes, double screen_width, double screen_height, const Perspective_camera &camera, double average_height)
Prune the deva boxes based on the average entity height.
Definition: psi_util.cpp:140
virtual void set_orientation(const kjb::Quaternion &q)
Alias of set_angles_from_quaternion()
Definition: perspective_camera.h:401
kjb::Perspective_camera make_camera(double height, double tilt, double focal_length)
Definition: psi_util.h:95
void unstandardize(Vector &v, double cam_width, double cam_height)
Changes vector to unstandard (image) coordinate system.
Definition: pt_util.h:83
Class representing an axis-aligned, 2D rectangle.
This class implements matrices, in the linear-algebra sense, with real-valued elements.
Definition: m_matrix.h:94
void standardize(Deva_skeleton_boxes &boxes, double cam_width, double cam_height)
move coordinate ssystem origin to center of image
Definition: psi_deva_skeleton.cpp:156
Axis_aligned_rectangle_2d Bbox
Definition: psi_deva_skeleton.h:32
Definition for the Vector class, a thin wrapper on the KJB Vector struct and its related functionalit...