# Recognizing and Recovering Ball Motion Based on Low-Frame-Rate Monocular Camera
## 3 Method
### Acquiring Contours
#### 3.2.3 Concatenating Candidate Blocks  
A precondition for reconstructing a sphere's motion is to obtain its continuous projection. The more continuous the projection, the more contour points it contains that can be used to analyze the sphere's position to reconstruct the motion. However, due to the high speed of the sphere's movement, its projection is difficult to keep continuous. Taking Figure 6 for example, the image contains the contours of the streak candidate blocks identified using the method proposed in Section 3.2.1. Block B56 and B40 are discrete but belong to the same streak. To reconstruct the sphere motion, discrete blocks such as Block B56 and B40 must be concatenated. The criterion for determining whether candidate blocks are from the same projection is to determine whether the blocks are collinear. Since candidate blocks belonging to the same  
Figure 6: Due to noise, a trace is identified as multiple discrete blocks. Block B56 and B40 should belong to the same streak (in red dashed line). projection must be collinear, obtaining the position and orientation of the blocks becomes a prerequisite for determining the collinearity of the blocks. We first focus on the position and orientation of blocks. An ideal projection has roughly parallel lateral contours on both sides, with a narrow rectangle overall appearance. Therefore, the ideal candidate blocks that make up the projection could be similarly represented as rectangles. When the shape of the block is rectangular, it is easy to calculate the position and orientation of the block based on the properties of a rectangle. However, in practice, blocks obtained from a binarized image are irregularly shaped. Our idea for obtaining their positions and orientations is to convert the candidate blocks into rectangles. By observing the candidate blocks, we found that the length information of the blocks is usually clear, but the width information is severely lost. Therefore, we first obtain the length information and then infer the approximate width of the blocks based on the areas. We take the following steps to convert candidate blocks into rectangles. First, the block is fitted using a straight line which is regarded as its orientation. The fitting line will intersect the ends of the contour, and the width of the rectangle equals the distance between the intersections. Then, the height of the rectangle is obtained as the ratio of the area to the width. Figure 7a is a simulation of a streak containing the irregular block and its fitting line. The irregular block is transformed into a rectangle in Figure 7b. The center of the rectangle replaces the position of the streak. Using the regularized rectangle instead of the block's contour, we obtained each candidate block's position and orientation. After determining the position and orientation of each candidate block, we determine whether these blocks are collinear. In the ideal case, determining whether candidate blocks are collinear is a matter of determining whether their fitted straight lines overlap. However, due to the unavoidable error in the fitting result, the blocks on the same projection have different fitted lines. Thus, it is difficult to determine whether the blocks are collinear using the fitted straight lines alone. In this regard, we define a criterion for block collinearity. For each rectangle along the direction, we defined the region between two diagonals as the collinear region for other blocks. When both blocks fall in each other's collinear region, they are considered collinear. Taking Figure 7c for example, the collinear region of the green block contains the orange block. Meanwhile, the green block is also within the collinear region of the orange block. So these two blocks are collinear. In contrast, the blue block is not within the collinear regions of any block, so the blue block is not collinear with others.