Oriented Boxes – When to Rotate the Bounding Box

An object lying diagonally defeats the rectangle. The box aligned on the image axes surrounds it without describing it, and the solution consists in rotating the rectangle rather than tightening it further. This article sets out that variant. It extends the article on tightness rules.

What tilt costs

Five effects accompany a tilted object in bounding box work. The box’s area grows without the object itself changing. The proportion of background included then rises sharply. Two neighbouring objects see their respective boxes overlap. The dimensions read no longer match those of the object. And the orientation, often the most useful information, is lost entirely. One important practical consequence follows. Those five effects all worsen together as the object grows longer, a square shape hardly suffering from tilt whereas an elongated shape becomes unrecognisable within its own rectangle.

The uses that call for this variant

Six applications justify an oriented bounding box. Aerial views, where nothing any longer imposes a common orientation. Port scenes or angled parking layouts. Text photographed at some arbitrary angle. Manufactured parts laid out freely. Very elongated objects met in industrial settings. And crops or plots oriented according to the terrain. One important observation follows for a bounding box project. The first application is the most common and the least discussed, an overhead view purely removing the vertical reference that makes objects naturally aligned in an ordinary image.

What the angle introduces as ambiguity

Five questions arise as soon as an angle appears in bounding box work. The origin of the angle as well as its direction of rotation. The interval adopted, across a half turn or across a full turn. The side that must be taken as the object’s length. The treatment of an object whose front and rear differ clearly. And the conduct to adopt when facing an almost square object. One practical consequence follows. The last question produces an unpleasant instability, an almost square object swinging wholly through a quarter turn depending on the reading, which creates total disagreement over a box that is nonetheless correct on both sides.

What verifying the real gain presupposes

Five measurements establish the interest of this variant. The proportion of objects genuinely tilted within the corpus. The average ratio between the objects’ length and width. The area gained compared with a plain aligned box. The frequency of overlaps that orientation removes. And the use foreseen for the angle once it is delivered. One important observation follows for a bounding box project. The second measurement decides almost on its own, an object whose length clearly exceeds its width drawing considerable benefit from rotation whereas a stocky object gains almost nothing, which makes this calculation preferable to any visual impression.

What the convention must fix

Six points make an orientation instruction genuinely applicable. The origin as well as the direction in which the angle is measured. The exact interval of the values admitted. The rule designating the length among the two sides. The fate given to almost square objects. Whether or not the object’s own direction is taken into account. And the angle gap tolerated between two distinct annotations. One important observation follows for a bounding box project. The last point is neglected as it was on tightness and weighs more heavily, a gap of a few degrees only looking minimal while shifting considerably the corners of an elongated box.

What this format costs to produce

Four gaps separate this variant from the classic bounding box. An additional parameter to set for each one of the objects. A far longer adjustment, the angle and the sides interacting constantly. Markedly more thorough training for the operators. And an appreciably less immediate visual control. One important practical consequence follows. Those four gaps place this variant between the rectangle and the polygon, its cost staying markedly below that of an outline while exceeding that of an ordinary box, which often makes it the compromise projects were seeking without knowing of it.

What measuring the angle demands

Four indicators describe the quality of an oriented annotation. The average angle gap observed between two annotations of the same object. The proportion of objects where the angle differs by a quarter turn. The overlap effectively obtained between the two oriented boxes. And the correlation between the angle gap and the object’s elongation. One important practical consequence follows. The second indicator isolates a defect of convention rather than a defect of drawing, a gap of a quarter turn being unable to result from imprecision, which points immediately to a rule badly understood or badly written.

What conversion to an aligned box loses

Four pieces of information disappear during this conversion. The angle itself, which now has nowhere to be held. The object’s real dimensions, replaced by those of the envelope. The separation between two neighbouring objects the overlap erases. And the very possibility of returning to the original representation. One important observation follows for a bounding box project. This conversion follows the same one-way street as the previous chapter’s, an oriented box degrading into an aligned box effortlessly and never the reverse, which permits producing once and serving both uses.

What throughput loses to orientation

Four factors lengthen the time spent per object. Setting the angle is added to positioning the sides. Each angle correction shifts all four corners at once. The final adjustment demands several back and forth moves. And hesitation over square objects interrupts the rhythm. One important observation follows for a bounding box project. The second factor explains most of the extra cost, an angle and dimensions correcting each other where an aligned box is set side by side, which makes the drawing slower without the operator producing any more visible information.

What the corpus must cover here

Five situations deserve an explicit place in the corpus. Objects oriented across the whole range of possible angles. Almost square objects, where the convention is genuinely tested. Very elongated objects, where the gain becomes greatest. Neighbouring objects that only orientation separates. And objects whose front and rear direction genuinely matters. One important practical consequence follows for a bounding box project. The first situation is often missing without anyone noticing, a corpus drawn from one same shooting campaign showing orientations concentrated around a few values, which leaves the system helpless before the angles it has never seen.

Three errors proper to this variant

Three bounding box defects belong to the addition of the angle. An angle convention purely absent, letting each tool impose its own. An almost square object handled differently by each operator. And a variant adopted on objects that draw no real benefit from it. Those three defects produce visually correct boxes, they reveal themselves only by comparing two annotations or by using the angle, and their common point is to belong to a parameter the classic box never had to define.

What the annotator must know here

Five kinds of knowledge condition correct work on this variant. The angle convention finally adopted, with its origin and its direction. The rule designating the length among the two sides. The treatment given to objects whose orientation stays undecidable. The order of movements avoiding needless back and forth. And the moment to flag a case rather than settle it alone. One important observation follows for a bounding box project. The fourth point is rarely taught and saves a great deal, an operator setting the angle before the dimensions working markedly faster than one proceeding in the reverse order, which belongs to a method instruction rather than to an annotation rule.

What the delivery format requires here

Four choices condition the reuse of an oriented corpus. The description of the box, by its four corners or by centre and angle. The unit of the angle as well as the convention documented alongside. A field flagging objects whose orientation stays uncertain. And the possible supply of the strictly equivalent aligned box. One important practical consequence follows for a bounding box project. The first choice causes the same silent conversions as on the classic box, a description by corners and one by centre and angle giving files of identical appearance and different geometries, which lets an offset pass every automatic check.

What pre-annotation changes here

Four effects follow from using an oriented proposal. The proposed angle is adjusted far faster than it is drawn from scratch. The tool’s convention silently imposes itself on the corpus. Almost square objects then receive an arbitrary but constant angle. And the operator very rarely corrects an angle that already looks plausible. One important observation follows for a bounding box project. The third effect deserves attention, an automatic proposal systematically settling square objects the same way producing an apparent consistency that masks a convention never discussed, which makes the defect harder to spot than plain dispersion.

What the first batch must establish

Four results justify a trial batch before production. The angle gap observed between two operators on the same objects. The exact proportion of objects whose orientation proved undecidable. The time overhead measured against a plain aligned box. And the area gain effectively obtained on this precise corpus. One important practical consequence follows for a bounding box project. The last two results are read together and settle matters, a time overhead exceeding the area gain indicating that this variant does not suit this corpus, which gives a quantified answer where the debate is usually a matter of conviction.

What the client must specify here

Four pieces of information come from the client rather than from the provider. The precise use they genuinely intend to make of the delivered angle. The angle convention expected by their own processing chain. The meaning they attach to an object’s front in their field. And the degree of angular precision they truly need. One important observation follows for a bounding box project. The second piece avoids a full rework, a corpus annotated to one convention and used under another producing angles offset by a quarter turn throughout, which is corrected by calculation when detected and never when ignored.

What quality control must target here

Four arrangements suit this variant. A double annotation bearing on the most elongated objects alone. A superimposed display of the two boxes permitting the angle to be judged. A sorting of gaps according to whether they are continuous or a quarter turn. And a specific control bearing on objects close to square. One important observation follows for a bounding box project. The first arrangement concentrates the effort where it pays, a stocky object tolerating a large angle gap with no visible consequence whereas a very elongated object becomes unrecognisable for the same gap, which makes a uniform control less effective than one proportioned to elongation.

What this variant presupposes of the tool

Five functions make this work practicable. A genuinely continuous rotation rather than one in fixed steps. A permanent display of the angle’s current value. A fast switch between aligned box and oriented box. An optional constraint bearing on the admitted interval. And a visualisation of the side designated as the length. One important practical consequence follows for a bounding box project. The last function on its own removes the main source of disagreement, an operator seeing on screen which side counts as the length being unable to be wrong by a quarter turn, which replaces an instruction hard to remember with a marker visible at all times.

What this format changes about a project’s economics

Four effects distinguish the budget of an oriented box project. The cost per object exceeds that of an aligned box without reaching the polygon’s. Initial training lengthens by a few days. Quality control then demands an arrangement specific to the angle. And the corpus produced also serves aligned box uses. One important observation follows for a bounding box project. The last effect partly offsets the first three, an oriented corpus staying usable by a client who does not exploit the angle, which makes the extra cost more bearable on a lasting programme than on a one-off assignment.

What the provider brings here

Four contributions distinguish a serious engagement on this variant. A measurement of the objects’ elongation before any recommendation. An angle convention written, illustrated and tested on a batch. A specific control of quarter turn gaps. And a delivery permitting conversion to an aligned box. One important practical consequence follows. The first contribution avoids the most frequent expense on this subject, a project adopting oriented boxes on principle while its objects are stocky paying for an extra parameter for a negligible gain, which is observed within an hour and never afterwards.

Approaching an oriented box project

Five questions scope such a bounding box project. Are the objects elongated. Otherwise the benefit stays small. Is their orientation free. Otherwise the rectangle suffices. Will the angle be used. That changes the requirement. Is the angle convention written. Without it everything diverges. And are square objects frequent. They cause trouble. Those five answers determine the interest of this variant. Asking them before production avoids a parameter paid for with no use or a convention left to each person.

The question that frames the choice

One question determines the usefulness of this variant in bounding box work. Is the objects’ orientation information or an accident. An accident, a shooting tilt or an arbitrary pose, does not deserve annotating and is satisfied by a correctly tightened aligned rectangle. Information, a vehicle’s heading, a part’s axis or a text’s direction, justifies the angle and makes it usable downstream. That question belongs to what the use will do with the angle, it is asked before the first image, and it separates a useful parameter from one paid for with no destination.

Three decisions before producing

Three decisions commit an oriented bounding box project. Measuring the objects’ average elongation before adopting this variant. Fixing the origin, the direction and the interval of the angle in writing. And settling the case of almost square objects before it arises. Those three decisions cost an hour, they precede the first image, and their absence produces an angular dispersion nothing will permit explaining.

Three checks on an oriented corpus

Three checks qualify a set of oriented bounding boxes. The angle convention, written with its origin and its direction. The rule applied to almost square objects. And the proportion of quarter turn gaps between two operators. Those three checks are each asked in one question, they require no particular competence, and their absence indicates a corpus whose angles will not be usable as delivered.

What this chapter teaches

One cross-cutting observation deserves closing this examination. Adding a parameter amounts to adding a convention to settle. Three findings compose it. An elongated shape becomes unrecognisable within its aligned rectangle. An almost square object swings a quarter turn depending on the reading. And a gap of a few degrees shifts considerably the corners of an elongated box. That finding extends the preceding chapter, the precision gained on shape being paid in fresh ambiguity over the angle.

What this chapter shares with the previous ones

Three findings recur from the start of this course. Every parameter added calls for an additional convention. A defect of convention differs from a defect of drawing by its form. And the fine geometry degrades towards the coarse and never the reverse. One important practical consequence follows for a bounding box project. The second finding supplies a transferable diagnostic tool, a continuous error signalling a problem of method and a discrete error a problem of rule, which permits directing the correction without examining every case.

What this chapter leaves to the next

A well oriented box stays uncertain if the object is half hidden. Three questions stay open in bounding box work. What to do with the part of an object nothing shows. How to handle an object cut by the edge of the image. And up to what degree of masking an object deserves annotating. Those three questions belong to occlusion and truncation, which constitute the subject of the following chapter.

Why the measurement should precede the recommendation

One point about how this variant gets proposed belongs at the close. Oriented boxes are often adopted because they sound more rigorous. Three reasons follow in bounding box work. The word oriented suggests a corpus of higher quality. Nobody wants to argue for the coarser option in a scoping meeting. And the extra cost is small enough to pass without scrutiny. One important practical consequence follows for a bounding box provider. Producing the elongation figure before recommending anything protects both parties, since it either justifies the variant with evidence or spares the client a parameter they would have paid for and never used, and either outcome leaves the provider having argued from the corpus rather than from the vocabulary.

Common mistakes

These failures recur often enough that naming them is usually enough to avoid them.
  • Adopting an oriented box without defining the origin of the angle.
  • Leaving the interval of admitted angles to each person’s judgement.
  • Omitting the rule designating the length among the two sides.
  • Neglecting the case of almost square objects.
  • Using this variant on compact objects with no real gain.
  • Confusing the box’s orientation with the object’s direction.
  • Omitting the tolerated angle gap threshold between two annotations.
  • Converting to an aligned box without flagging the information lost.
  • Mixing aligned and oriented boxes without documenting it.
  • Measuring quality without measuring dispersion on the angle.

What to take away

Rotating the rectangle solves one problem and introduces another. Three readings emerge. An elongated shape becomes unrecognisable within its aligned rectangle, which makes this variant useful exactly where the classic box loses most and useless elsewhere. An almost square object swings a quarter turn depending on the reading, which produces total disagreement over a box that is nonetheless correct on both sides and requires an explicit rule. And a gap of a few degrees shifts considerably the corners of an elongated box, which makes the angle gap threshold even more determining than the tightness one. For masked objects, the article on occlusion and truncation details the approach. For file formats, the article on COCO, YOLO and Pascal VOC compares them. To explore delivery arrangements, supported formats and applicable control mechanisms, see our dedicated page on 2D and 3D annotation. And if you are preparing a detection project, let us discuss your need.
Tags

Découvrez nos articles