Machine vision-based dimensional measurement scoring system and method

By establishing a multi-step measurement framework and dynamically detecting image features, the problem of the inability to automatically analyze continuous operation processes in existing technologies has been solved, enabling quantitative evaluation of operation quality and improving the accuracy of measurement results.

CN121452935BActive Publication Date: 2026-05-01QINGDAO UNIV OF TECH +1
View PDF 2 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
QINGDAO UNIV OF TECH
Filing Date
2026-01-05
Publication Date
2026-05-01

AI Technical Summary

Technical Problem

Existing machine vision-based dimensional measurement methods cannot automatically analyze and logically understand continuous operation processes, and ignore the stability and positioning trajectory precision during key measurement actions, resulting in a lack of effective means for operation quality assessment.

Method used

By establishing a multi-step measurement framework, continuous spatial location streams and timestamp streams are captured simultaneously, pause events are identified and associated with standard measurement stages, image features are dynamically detected, local trajectory complexity indices are calculated, and a comprehensive measurement score is generated by combining overall time consumption and sequence deviation factors.

Benefits of technology

It enables automated verification and quality assessment of the operation process, quantifies the stability and fine motion control capabilities of operators in performing key measurement actions, and improves the accuracy and repeatability of measurement results.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121452935B_ABST
    Figure CN121452935B_ABST
Patent Text Reader

Abstract

The application relates to the technical field of machine vision and operation evaluation, and discloses a size measurement scoring system and method based on machine vision. The method comprises the following steps: synchronously capturing a continuous spatial position stream and a time stamp stream in a measurement process, analyzing a pause event and associating the pause event with a pre-defined standard measurement stage, forming a step sequence to check a logical sequence and generating a sequence deviation factor. Meanwhile, preset image features are dynamically detected and their feature capture moments are recorded, a position point set in a time window before and after the moment is extracted, and a local trajectory complexity index is calculated. The original operation efficiency value is calculated by comprehensively considering the overall time consumption, the sequence deviation factor and the local trajectory complexity index, and is normalized and fused with a reference size value, and finally a comprehensive measurement score is output. The application realizes automatic comprehensive evaluation of the standardization of a measurement operation process and the stability of an operation process.
Need to check novelty before this filing date? Find Prior Art

Description

Machine Vision-Based Size Measurement and Scoring System and Method Technical Field

[0001] This invention relates to the field of machine vision and operational evaluation technology, specifically to a machine vision-based size measurement and scoring system and method. Background Technology

[0002] In the field of industrial measurement, machine vision-based dimensional measurement methods have been widely applied. Existing technical solutions mainly rely on discrete, triggered image acquisition and static analysis of the measuring tool or the object being measured. The system typically captures a single frame image to identify feature locations and calculate dimensions after the operator completes a measurement action and remains stationary. The core of this technical approach is to acquire and process isolated state points representing the measurement result, and its operating mode passively responds to the operator's explicit actions or external commands.

[0003] These conventional technologies have limitations. Their technical architecture cannot automatically parse and logically understand continuous, natural operational processes. In actual operation, the execution order of steps and the standardization of transitions are beyond the system's perception range, resulting in a lack of means to evaluate the standardization of the operational process itself. Furthermore, existing methods only focus on the spatial coordinates in the final static pose, completely ignoring the continuous dynamic trajectory information acquired during the acquisition of those coordinates. Process data reflecting operational quality, such as stability during key measurement actions and the precision of the positioning trajectory, are ignored by the system, yet this data is crucial for evaluating the rigor of the measurement and the repeatability of the results.

[0004] A technology is needed to automatically parse structured measurement step sequences from continuous operational data streams and to achieve dynamic quality assessment of the execution process of key measurement actions. This requires the system to have the ability to identify key stages and associate them with standard steps from coherent spatiotemporal data, as well as the ability to quantitatively analyze the local operational trajectory characteristics around the measurement moment, thereby establishing a comprehensive evaluation system that integrates process quality and result accuracy. Summary of the Invention

[0005] The purpose of this invention is to provide a machine vision-based size measurement and scoring system and method to solve the problems mentioned in the background art.

[0006] To achieve the above objectives, the present invention provides a machine vision-based size measurement and scoring method, the method comprising:

[0007] A multi-step measurement framework for the object under test is established, and a continuous spatial position stream and a corresponding timestamp stream are captured synchronously during the measurement process. The continuous spatial position stream is analyzed to identify pause events, and each pause event is associated with a standard measurement stage in the multi-step measurement framework to generate an associated step sequence.

[0008] Based on the associated sequence of steps, the logical order of the standard measurement stage is checked to see if it is followed. When a logical order misalignment is found, a sequence deviation event is marked and a corresponding sequence deviation factor is generated.

[0009] In the continuous spatial position flow, it is dynamically detected whether an image region that conforms to the preset morphological characteristics appears. When the image region is detected, the moment when the image region that conforms to the preset morphological characteristics is detected is recorded as the feature capture moment. The set of position points within the time window before and after the feature capture moment is extracted and the set of position points is recorded as the effective measurement point set.

[0010] Calculate the local trajectory complexity index based on the effective set of measurement points;

[0011] The total time taken from the start to the end of the measurement is obtained, and the original operation efficiency value is calculated by combining the order deviation factor and the local trajectory complexity index.

[0012] The pre-stored reference size value for the object under test is introduced, and the original operating performance value is normalized and fused with the reference size value to finally output a comprehensive measurement score.

[0013] Preferably, the step of identifying pause events by parsing the continuous spatial location stream includes:

[0014] Set a minimum duration threshold and a maximum displacement tolerance threshold;

[0015] In the continuous spatial location stream, an analysis window of a fixed duration is slid in chronological order;

[0016] Calculate the standard deviation of the spatial coordinates of all points within each analysis window;

[0017] When the standard deviation of the spatial coordinates is less than the maximum displacement tolerance threshold, and the duration of this state exceeds the minimum duration threshold, it is determined that a pause event has occurred within the time period covered by the analysis window.

[0018] Extract the average spatial coordinates of all locations within the time period, and use them as the representative location of the pause event.

[0019] Preferably, the step of associating each pause event with a standard measurement phase in the multi-step measurement framework includes:

[0020] Obtain the theoretical spatial range of each standard measurement stage in the multi-step measurement framework;

[0021] Calculate the Euclidean distance between the representative location of the pause event and the center point of each theoretical spatial region.

[0022] The standard measurement stage corresponding to the theoretical spatial region with the smallest Euclidean distance is selected as the candidate correlation stage;

[0023] Verify whether the representative location of the pause event is within the theoretical spatial region of the candidate association stage;

[0024] If it falls within the range, the current pause event is successfully bound to the candidate associated stage, generating a step binding record;

[0025] All step binding records are compiled in chronological order to form the associated step sequence.

[0026] Preferably, the step of traversing and checking whether the logical order of the standard measurement phases is followed includes:

[0027] From the associated sequence of steps, extract the stage identifier of the standard measurement stage to which each step is bound;

[0028] The extracted stage identifiers are arranged in order to generate an actual execution sequence;

[0029] The actual execution sequence is compared bit by bit with the preset logical order in the multi-step measurement framework;

[0030] When a stage identifier is found in the actual execution sequence and its position in the preset logical order appears before the position corresponding to the previous stage identifier, it is determined that a sequence misalignment has occurred.

[0031] The total number of sequence misalignments that occur throughout the entire actual execution sequence is counted, and the total number of misalignments is converted into the sequence deviation factor according to a preset mapping relationship.

[0032] Preferably, the step of dynamically detecting whether an image region conforming to preset morphological characteristics appears includes:

[0033] Real-time acquisition of video frames from the measurement perspective captured by the image sensor on the measurement equipment;

[0034] Binarization segmentation is applied to each video frame to obtain the corresponding binary image;

[0035] In the binarized image, all connected pixel regions are found using a region growing algorithm;

[0036] Calculate the geometric feature descriptor for each connected pixel region, the geometric feature descriptor including area, perimeter, and rectangularity;

[0037] The geometric feature descriptor of each connected pixel region is matched with the feature descriptor in the pre-stored feature template library based on similarity.

[0038] When the matching similarity of a connected pixel region exceeds a preset similarity threshold, it is determined that an image region conforming to the preset morphological features has been detected.

[0039] Preferably, the step of calculating the local trajectory complexity index based on the effective set of measurement points includes:

[0040] Extract the spatial coordinates of each location point from the set of valid measurement points;

[0041] Fit the spatial coordinates of all locations into a smooth curve;

[0042] Calculate the variance of the first derivative sequence of the smooth curve, and denote the variance as the intensity of the direction change;

[0043] Calculate the average value of the curvature sequence of the smooth curve, and record the average value as the path curvature.

[0044] The local trajectory complexity index is obtained by weighted summing of the intensity of the directional change and the curvature of the path.

[0045] Preferably, the step of calculating the original operating performance value includes:

[0046] Obtain the first timestamp corresponding to the start time of the measurement and the second timestamp corresponding to the end time of the measurement;

[0047] Calculate the difference between the second timestamp and the first timestamp to obtain the total time spent;

[0048] Establish an efficiency calculation model that includes sequence deviation factor, local trajectory complexity index and total energy consumption;

[0049] The order deviation factor is input into the first calculation channel of the performance calculation model to obtain an order penalty component;

[0050] The local trajectory complexity index is input into the second calculation channel of the performance calculation model to obtain a trajectory regularization component.

[0051] The total time consumption is input into the third calculation channel of the performance calculation model to obtain a time efficiency component;

[0052] The sequential penalty component, trajectory normalization component, and time efficiency component are combined and operated to output the original operation efficiency value.

[0053] Preferably, the step of applying binarization segmentation to each video frame includes:

[0054] Select a global threshold for a specific color space channel in the video frame;

[0055] Compare the component value of each pixel in the video frame in that color space channel with the global threshold;

[0056] Pixels with component values ​​greater than the global threshold are set as foreground pixels, and pixels with component values ​​less than or equal to the global threshold are set as background pixels.

[0057] Perform a morphological opening operation on the image after setting to remove small noise points in the foreground;

[0058] The image after morphological opening is then subjected to morphological closing to fill the small holes in the foreground, resulting in the final binarized image.

[0059] Preferably, the step of fitting the spatial coordinates of all location points into a smooth curve includes:

[0060] The non-uniform rational B-spline curve fitting method is adopted, and the spatial coordinates of all position points in the effective measurement point set are used as control points.

[0061] Assign a weight value to each control point and determine a node vector;

[0062] The parametric equation of the smooth curve is generated based on the control points, the weight values, and the node vectors.

[0063] The coordinates of a series of densely sampled points on the curve are calculated using the parametric equations to characterize the fitted smooth curve.

[0064] Preferably, the present invention also includes a machine vision-based size measurement and scoring system, the system including a memory, a processor, and a computer program stored in the memory and running on the processor, wherein the processor, when executing the computer program, implements the steps of the machine vision-based size measurement and scoring method described above.

[0065] Compared with the prior art, the beneficial effects of the present invention are:

[0066] By synchronously capturing a continuous stream of timestamped spatial locations and automatically identifying and correlating pause events, a standardized sequence of steps can be reconstructed from unstructured, coherent operations. This enables the system to automatically verify the actual operational process according to a predefined logical order, generating a quantified sequence deviation factor when a step misalignment is detected. This method transforms the measurement of process standardization from a qualitative judgment into a calculable evaluation indicator, achieving an objective assessment of whether operators strictly adhere to standard operating procedures.

[0067] The system dynamically detects preset image features and records their occurrence times, then extracts a set of continuous position points within a time window before and after that moment to form an effective measurement point set. The local trajectory complexity index calculated based on this point set is essentially a quantitative description of the operator's fine motion control ability during the execution of key measurement actions. This index effectively reflects dynamic characteristics such as micro-jitter and unnecessary adjustments during the positioning process. Incorporating this index, which reflects process stability, into the evaluation system ensures that the final comprehensive score simultaneously reflects the accuracy of the measurement results and the quality of the operational process in obtaining those results, thus distinguishing operational performance with different levels of stability at the same result accuracy. Attached Figure Description

[0068] Figure 1 is a schematic diagram illustrating the working principle of the machine vision-based size measurement and scoring method of the present invention.

[0069] Figure 2 is a flowchart for identifying pause events;

[0070] Figure 3 is a line graph of the average Euclidean distance during the standard measurement phase;

[0071] Figure 4 is a multi-dimensional polygonal line graph of the geometric features of connected pixel regions;

[0072] Figure 5 is a flowchart for calculating the local trajectory complexity index. Detailed Implementation

[0073] The technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.

[0074] Referring to Figure 1, this invention provides a machine vision-based size measurement and scoring method. The method includes: establishing a multi-step measurement framework for the object under test; simultaneously capturing a continuous spatial position stream and corresponding timestamp stream generated by the measurement device during the measurement process; parsing the continuous spatial position stream to identify pause events; associating each identified pause event with a predefined standard measurement stage in the multi-step measurement framework to generate a sequence of associated steps arranged chronologically; based on this sequence of associated steps, traversing and checking whether the order of occurrence of the standard measurement stages follows the predefined logical order of the framework; when a misalignment is found, marking a sequence deviation event and generating a corresponding sequence deviation factor; during the capture of the continuous spatial position stream, synchronously and dynamically detecting whether an image region conforming to a preset morphological feature appears in the video stream acquired by the image sensor; once such an image region is detected, immediately recording the current moment as the feature capture moment, and extracting all position points within a certain time window before and after this moment to form an effective measurement point set; and calculating its local trajectory complexity index based on this effective measurement point set. The total time taken from the start to the end of the measurement is obtained. Combining the aforementioned sequence deviation factor and local trajectory complexity index, the original operational efficiency value is obtained through a preset efficiency calculation model. A pre-stored reference dimension value for the measured object is introduced, and the original operational efficiency value and the reference dimension value are normalized and fused together to finally output a comprehensive measurement score.

[0075] Example 1: Referring to Figure 2, a minimum duration threshold and a maximum displacement tolerance threshold are set. In a continuous spatial location flow, an analysis window of fixed duration is slid sequentially over time. The standard deviation of the spatial coordinates of all locations within each analysis window is calculated. When the standard deviation of the spatial coordinates is less than the maximum displacement tolerance threshold, and the duration of this low standard deviation exceeds the minimum duration threshold, a pause event is determined to have occurred within the time period covered by the analysis window. The average spatial coordinates of all locations within this time period are extracted as the representative location of the pause event.

[0076] In specific implementations, a minimum duration threshold and a maximum displacement tolerance threshold are set. The minimum duration threshold defines the shortest possible duration for an effective pause, while the maximum displacement tolerance threshold defines the maximum range of positional fluctuations within a point set that allows it to remain spatially stationary. In some embodiments, in a continuous spatial position flow, a fixed-length analysis window is slid sequentially over time; the length of the analysis window is predefined. For each analysis window, the standard deviation of the spatial coordinates of all position points within the window is calculated. The calculation of the standard deviation of the spatial coordinates characterizes the dispersion of all position points within the analysis window relative to their average position. The standard deviation of the spatial coordinates σ can be calculated using the following formula:

[0077]

[0078] in: Represents the standard deviation of spatial coordinates. This indicates the number of location points within the analysis window. Indicates the first Spatial coordinate vectors of a location point This represents the average vector of the spatial coordinates of all points within the analysis window. This represents the Euclidean norm of the vector. The calculated standard deviation of the spatial coordinates is used for comparison with the maximum displacement tolerance threshold.

[0079] In some embodiments, when the calculated standard deviation of spatial coordinates is less than a set maximum displacement tolerance threshold, and the duration for which the spatial coordinate standard deviation is below the maximum displacement tolerance threshold is continuously maintained exceeds a minimum duration threshold, a pause event is determined to have occurred within the time period covered by the current analysis window. It can be understood that the maximum displacement tolerance threshold defines the upper limit of the spatial density of a cluster of location points, and the minimum duration threshold defines the lower limit of the time this density state needs to be maintained; both together constrain the physical definition of a pause event. When multiple consecutive analysis windows satisfy the above conditions, and these windows collectively cover a continuous time period, this time period is identified as a complete pause event.

[0080] Optionally, after identifying the time period corresponding to the pause event, the average spatial coordinates of all location points within that time period are extracted as the representative location point of the pause event. The representative location point is calculated by taking the arithmetic mean of the spatial coordinate components of each location point captured within that time period to generate a new coordinate point.

[0081] Example 2: Obtain the theoretical spatial range of each standard measurement stage in the multi-step measurement framework. Calculate the Euclidean distance between the representative location of the pause event and the center point of each theoretical spatial range. Select the standard measurement stage corresponding to the theoretical spatial range with the smallest Euclidean distance as a candidate associated stage. Verify whether the representative location of the pause event is within the theoretical spatial range of the candidate associated stage. If it is, successfully bind the current pause event to the candidate associated stage, generating a step binding record. Gather all step binding records in chronological order to form an associated step sequence. Extract the stage identifier of the standard measurement stage bound to each step binding record from the associated step sequence, and arrange the extracted stage identifiers in order to generate an actual execution sequence. Compare the actual execution sequence with the preset logical order in the multi-step measurement framework position by position. When a stage identifier in the actual execution sequence is found to be in a position before the position corresponding to the previous stage identifier in the preset logical order, it is determined that a sequence misalignment has occurred. The total number of sequence misalignments that occur throughout the entire actual execution sequence is counted, and this total number is converted into a sequence deviation factor based on a preset mapping relationship.

[0082] In practice, the theoretical spatial region of each standard measurement stage in the multi-step measurement framework is obtained. This theoretical spatial region is a pre-defined boundary in space for each standard measurement stage. The Euclidean distance between the representative location point of the pause event and the center point of each theoretical spatial region is calculated. The calculation of the Euclidean distance quantifies the spatial proximity of the representative location point to the center of each theoretical spatial region. It can be calculated using the following formula:

[0083]

[0084] in: The three-dimensional spatial coordinates representing the location of the pause event. In a multi-step measurement framework, the first step is... The three-dimensional spatial coordinates of the center point of the theoretical spatial region within each standard measurement stage. That is, representing the position point and the first The Euclidean distance between the center points is compared. The Euclidean distances calculated for all standard measurement phases are also compared. The numerical value is used to select the standard measurement stage corresponding to the theoretical spatial region with the smallest Euclidean distance as the candidate correlation stage.

[0085] In some embodiments, it is verified whether the representative location of the pause event is within the theoretical spatial region of the candidate association stage. The verification process is completed by comparing whether each coordinate component of the representative location falls within the corresponding coordinate axis interval defined by the theoretical spatial region of the candidate association stage. If the representative location is within the theoretical spatial region of the candidate association stage, the current pause event is successfully bound to the candidate association stage, generating a step binding record containing the pause event identifier, representative location information, and the bound standard measurement stage identifier. All step binding records are compiled in chronological order to form an associated step sequence. From the associated step sequence, the stage identifier of the standard measurement stage bound to each step binding record is extracted sequentially. The stage identifier is a symbol that uniquely identifies a standard measurement stage. The extracted stage identifiers are arranged in the extraction order to generate an actual execution sequence, which reflects the order in which the standard measurement stages associated with the pause event are triggered during the operation.

[0086] Optionally, the actual execution sequence is compared bit-by-bit with the preset logical order in the multi-step measurement framework. The preset logical order in the multi-step measurement framework is an ordered list of standard measurement stage identifiers, defining the correct order of operations. During the bit-by-bit comparison, when a stage identifier is found in the actual execution sequence whose position number in the preset logical order appears before the corresponding position number of the preceding stage identifier in the preset logical order, a sequence misalignment is determined to have occurred. It can be understood that the determination of a sequence misalignment means that a standard measurement stage that should theoretically be executed later has been executed prematurely in the operation process. The total number of sequence misalignments occurring throughout the entire actual execution sequence is counted, and the total number is converted into a sequence deviation factor according to a preset mapping relationship. The sequence deviation factor is a numerical value used to quantify the degree of sequence error.

[0087] Referring to Figure 3, this is a line graph of the average Euclidean distance during the standard measurement stage. The vertical axis, "Average Euclidean Distance," represents the average three-dimensional spatial distance between all points at the current stage of the measurement operation and the center point of the corresponding theoretical reference area. A higher value indicates a greater deviation of the operation position from the reference area, resulting in lower accuracy. The horizontal axis covers the entire standard process of dimensional measurement, corresponding to the key operational steps in machine vision measurement. "Extracting dimensional features" is clearly the stage with the highest risk of deviation, requiring focused optimization of operational procedures at this stage. This graph serves as a process quality monitoring tool for machine vision dimensional measurement—by tracking the degree of spatial deviation at each stage, it achieves closed-loop management of "visualizing the operation process → locating weak points → targeted optimization of accuracy," ultimately improving the overall accuracy of dimensional measurement.

[0088] Example 3: Real-time acquisition of video frames from the measurement perspective captured by the image sensor on the measuring device. Binarization segmentation is applied to each video frame. A global threshold is selected for a specific color space channel of the video frame. The component value of each pixel in the video frame in that color space channel is compared with the global threshold. Pixels with component values ​​greater than the global threshold are set as foreground pixels, and pixels with component values ​​less than or equal to the global threshold are set as background pixels. Morphological opening is performed on the image after setting to remove small noise points in the foreground. Morphological closing is performed on the image after morphological opening to fill small holes in the foreground, resulting in the final binarized image. All connected pixel regions are found in the obtained binarized image using a region growing algorithm. The geometric feature descriptor of each connected pixel region is calculated, including area, perimeter, and rectangularity. The geometric feature descriptor of each connected pixel region is compared with the feature descriptors in a pre-stored feature template library for similarity matching. When the similarity of a connected pixel region exceeds a preset similarity threshold, an image region conforming to the preset morphological features is detected.

[0089] In the specific implementation, video frames from the measurement perspective are acquired in real time by the image sensor on the measuring device, which continuously captures images during the measurement process. Binarization segmentation is applied to each real-time acquired video frame to separate the foreground from the background. Specifically, a global threshold is selected for a specific color space channel of the video frame; the color space can be grayscale, a component channel of HSV, or others. The component value of each pixel in the video frame in that specific color space channel is compared with the global threshold; this comparison is performed pixel-by-pixel. Pixels with component values ​​greater than the global threshold are set as foreground pixels, and pixels with component values ​​less than or equal to the global threshold are set as background pixels. An initial binary image is generated through this comparison and setting operation. A morphological opening operation is performed on the set image to remove small noise points in the foreground; this morphological opening operation is an erosion followed by dilation operation. A morphological closing operation is then performed on the image after the morphological opening operation to fill small holes in the foreground; this morphological closing operation is a dilation followed by erosion operation.

[0090] In some embodiments, a region growing algorithm is used to find all connected pixel regions in the final binarized image. The region growing algorithm aggregates neighboring pixels with similar attributes, starting from a seed pixel. A geometric feature descriptor is calculated for each connected pixel region, including area, perimeter, and rectangularity. The area describes the total number of pixels contained in the connected pixel region, the perimeter describes the length of the outer boundary of the connected pixel region, and the rectangularity describes the ratio of the area of ​​the connected pixel region to its smallest bounding rectangle. The geometric feature descriptor of each connected pixel region is then matched for similarity with feature descriptors in a pre-stored feature template library. The feature template library stores standard geometric feature data of the preset morphological features to be detected. The results of the similarity matching are then presented. It can be calculated using the following formula:

[0091]

[0092] in: This represents the area of ​​the currently connected pixel region. This represents the perimeter of the currently connected pixel region. This represents the rectangularity of the currently connected pixel region. The first one in the feature template library The area of ​​each feature template, The first one in the feature template library The perimeter of each feature template, The first one in the feature template library The rectangularity of each feature template. These are preset weighting coefficients corresponding to the three feature components: area, perimeter, and rectangularity, respectively. , Indicates the currently connected pixel region and the first... The matching similarity of each feature template. When there is a connected pixel region, the matching similarity... When the similarity exceeds a preset threshold, it is determined that an image region matching the preset morphological characteristics has been detected in the current video frame.

[0093] Referring to Figure 4, this is a multi-dimensional line graph showing the geometric features of connected pixel regions. The area fluctuates significantly, peaking in regions 2, 5, and 8 (approximately 800), while regions 4, 7, and 10 are at their lowest points (approximately 500). The perimeter remains relatively stable between 200 and 300, with only regions 4 and 7 showing a slight decrease. Rectangularity reflects the degree to which the region's shape resembles a rectangle; regions 2, 5, and 8 have a rectangularity close to 0.95, while region 9 drops to 0.6. This graph is used for morphological feature analysis in machine vision dimensional measurement. Fluctuations in area and perimeter reflect the spatial proportion and boundary complexity of different regions; changes in rectangularity can help identify the shape type of the target region; this multi-dimensional comparison provides geometric feature basis for subsequent "feature template matching," helping to determine whether a region conforms to a preset shape.

[0094] Example 4: Referring to Figure 5, the spatial coordinates of each location point are extracted from the effective measurement point set. A non-uniform rational B-spline curve fitting method is used to take the spatial coordinates of all location points in the effective measurement point set as control points. A weight value is assigned to each control point, and a node vector is determined. Based on these control points, weight values, and node vectors, a parametric equation for a smooth curve is generated. The coordinates of a series of densely sampled points on the curve are calculated using this parametric equation to characterize the fitted smooth curve. The variance of the first derivative sequence of this smooth curve is calculated, and this variance is denoted as the intensity of directional change. The average value of the curvature sequence of the smooth curve is calculated, and this average value is denoted as the path curvature. The weighted sum of the intensity of directional change and the path curvature is the local trajectory complexity index.

[0095] In practice, the spatial coordinates of each location point are extracted from the effective measurement point set, which is the collection of all location points captured within a specific time window before and after the feature capture time. A non-uniform rational B-spline curve fitting method is used, with the spatial coordinates of all location points in the effective measurement point set serving as control points. A weight value is assigned to each control point, adjusting its influence on the curve shape. Simultaneously, a node vector is determined; this node vector is a non-decreasing sequence of real numbers used to define the parameterization range of the B-spline basis function. Based on the control points, the weight values ​​assigned to each control point, and the node vector, the parametric equation of the smooth curve is generated. The coordinates of a series of densely sampled points on the curve are calculated using the parametric equation of the smooth curve; these coordinates characterize the fitted smooth curve.

[0096] In some embodiments, the variance of the first derivative sequence of the fitted smooth curve is calculated. The first derivative describes the tangent direction or rate of change of the curve at each parameter point, and the calculated variance is denoted as the intensity of directional change. The average value of the curvature sequence of the smooth curve is calculated. Curvature describes the degree of curvature of the curve at a certain point, and the calculated average value is denoted as the path curvature. To synthesize a dimensionlessly consistent local trajectory complexity index, the intensity of directional change and the path curvature are standardized respectively. Local Trajectory Complexity Index The calculation formula is:

[0097]

[0098] in: This represents the calculated intensity of the directional change. This indicates the calculated path curvature. It is a preset reference direction change intensity constant value. It is a preset reference path curvature constant value. and These are the preset weighting coefficients for the standardized directional change intensity component and the path curvature component. Optional, the weighting coefficients... and The sum of is 1, see Table 1.

[0099] Table 1: Parameters for Calculating Local Trajectory Complexity

[0100]

[0101] Example 5: Obtain the first timestamp corresponding to the start time of the measurement and the second timestamp corresponding to the end time of the measurement, and calculate the difference between the second timestamp and the first timestamp to obtain the total time consumption. Establish an efficiency calculation model that includes a sequence deviation factor, a local trajectory complexity index, and the total time consumption. Input the sequence deviation factor into the first calculation channel of the efficiency calculation model to obtain a sequence penalty component. Input the local trajectory complexity index into the second calculation channel of the efficiency calculation model to obtain a trajectory normalization component. Input the total time consumption into the third calculation channel of the efficiency calculation model to obtain a time efficiency component. Perform a synthesis operation on the sequence penalty component, the trajectory normalization component, and the time efficiency component to output the original operation efficiency value.

[0102] In practical implementation, the first timestamp corresponding to the start time of the measurement and the second timestamp corresponding to the end time of the measurement are obtained. The first and second timestamps are values ​​with a unified time reference obtained from the time service of the measurement system. The difference between the second and first timestamps is calculated, and this difference represents the total time consumed from the start to the end of the measurement operation. An efficiency calculation model is established, incorporating a sequence deviation factor, a local trajectory complexity index, and the total time consumed. This model defines the mathematical relationship from input parameters to the output original operation efficiency value. In practical implementation, the efficiency calculation model defines a mathematical framework that uses the sequence deviation factor, local trajectory complexity index, and total time consumed as input parameters. These parameters are converted into intermediate components through a pre-defined processing channel and finally synthesized into the original operation efficiency value. The performance calculation model comprises three independent computational channels: the first channel handles the order deviation factor by multiplying it by a preset penalty coefficient to generate an order penalty component; the second channel handles the local trajectory complexity index by multiplying it by a preset normalization coefficient to generate a trajectory normalization component; and the third channel handles the overall time consumption by performing a mathematical transformation on the overall time consumption, such as a reciprocal operation, and multiplying it by a scaling factor to generate a time efficiency component. The design of these computational channels ensures that each input parameter can be independently quantified and adjusted to reflect its impact on operational performance across different dimensions. Subsequently, the model outputs the original operational performance value by performing a weighted summation of the order penalty component, trajectory normalization component, and time efficiency component. The weighting coefficients are preset based on the relative importance of each component, ensuring dimensional consistency and rationality in the synthesis process.

[0103] In some embodiments, a sequence deviation factor is input to the first calculation channel of the performance calculation model. The first calculation channel processes the sequence deviation factor to obtain a sequence penalty component. It can be understood that the processing in the first calculation channel may involve multiplying the sequence deviation factor by a preset penalty coefficient to obtain the sequence penalty component. A local trajectory complexity index is input to the second calculation channel of the performance calculation model. The second calculation channel processes the local trajectory complexity index to obtain a trajectory normalization component. It can be understood that the processing in the second calculation channel may involve multiplying the local trajectory complexity index by a preset normalization coefficient to obtain the trajectory normalization component. The total time consumption is input to the third calculation channel of the performance calculation model. The third calculation channel processes the total time consumption to obtain a time efficiency component, which can be obtained by mathematically transforming the total time consumption. To ensure dimensional consistency in the composite operation, the sequence penalty component, trajectory normalization component, and time efficiency component are standardized. Original operational performance value. The calculation formula is:

[0104]

[0105] in: This represents the sequential penalty component output from the first computation channel. This represents the trajectory normalization component output from the second calculation channel. Indicated by total time The time efficiency component is the input and the output from the third computation channel. It is a preset reference value for the sequential penalty component. It is a preset reference value for trajectory normalization components. It is a preset reference value for the time efficiency component. , , These are the preset composite weight coefficients for the standardized sequential penalty component, trajectory regularization component, and time efficiency component.

[0106] It should be noted that, in this document, relational terms such as "first" and "second" are used only to distinguish one entity or operation from another, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Furthermore, the terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such process, method, article, or apparatus.

[0107] Although embodiments of the invention have been shown and described, it will be understood by those skilled in the art that various changes, modifications, substitutions and alterations can be made to these embodiments without departing from the principles and spirit of the invention, the scope of which is defined by the appended claims and their equivalents.

Claims

1. A machine vision-based size measurement and scoring method, characterized in that, include: A multi-step measurement framework for the object under test is established, and a continuous spatial position stream and a corresponding timestamp stream are captured synchronously during the measurement process. The continuous spatial position stream is analyzed to identify pause events, and each pause event is associated with a standard measurement stage in the multi-step measurement framework to generate an associated step sequence. Based on the associated step sequence, the logical order of the standard measurement stage is checked for compliance. When a logical order misalignment is detected, a sequence deviation event is marked and a corresponding sequence deviation factor is generated. In the continuous spatial position flow, the presence of an image region conforming to a preset morphological feature is dynamically detected. When the image region is detected, the moment when the image region conforming to the preset morphological feature is detected is recorded as the feature capture moment. The set of position points within the time window before and after the feature capture moment is extracted and recorded as the effective measurement point set. The local trajectory complexity index is calculated based on the effective measurement point set. The total time from the start to the end of the measurement is obtained, and the original operation efficiency value is calculated by combining the sequence deviation factor and the local trajectory complexity index. A pre-stored reference size value for the measured object is introduced, and the original operation efficiency value and the reference size value are normalized and fused to finally output a comprehensive measurement score.

2. The machine vision-based size measurement and scoring method according to claim 1, characterized in that, The step of identifying pause events by parsing the continuous spatial location flow includes: setting a minimum duration threshold and a maximum displacement tolerance threshold; sliding an analysis window of fixed duration in the continuous spatial location flow in chronological order; calculating the standard deviation of spatial coordinates of all location points within each analysis window; determining that a pause event has occurred within the time period covered by the analysis window when the standard deviation of spatial coordinates is less than the maximum displacement tolerance threshold and the duration of this state exceeds the minimum duration threshold; and extracting the average spatial coordinates of all location points within this time period as the representative location point of the pause event.

3. The machine vision-based size measurement and scoring method according to claim 1, characterized in that, The step of associating each pause event with a standard measurement stage in the multi-step measurement framework includes: obtaining the theoretical spatial region range of each standard measurement stage in the multi-step measurement framework; calculating the Euclidean distance between the representative location point of the pause event and the center point of each theoretical spatial region range; selecting the standard measurement stage corresponding to the theoretical spatial region range with the smallest Euclidean distance as a candidate association stage; verifying whether the representative location point of the pause event is within the theoretical spatial region range of the candidate association stage; if it is within the range, successfully binding the current pause event with the candidate association stage and generating a step binding record; and aggregating all step binding records in chronological order to form the associated step sequence.

4. The machine vision-based size measurement and scoring method according to claim 3, characterized in that, The step of traversing and checking whether the logical order of the standard measurement stages is followed includes: extracting the stage identifier of the standard measurement stage bound to each step binding record from the associated step sequence; arranging the extracted stage identifiers in order to generate an actual execution sequence; comparing the actual execution sequence with the preset logical order in the multi-step measurement framework position by position; when a stage identifier is found in the actual execution sequence whose position in the preset logical order appears before the position corresponding to its previous stage identifier, it is determined that a sequence misalignment has occurred; counting the total number of sequence misalignments that occur in the entire actual execution sequence, and converting the total number into the sequence deviation factor according to a preset mapping relationship.

5. The machine vision-based size measurement and scoring method according to claim 1, characterized in that, The step of dynamically detecting whether an image region conforming to preset morphological characteristics exists includes: acquiring video frames from the measurement perspective collected by the image sensor on the measurement device in real time; applying a binarization segmentation operation to each video frame to obtain a corresponding binarized image; finding all connected pixel regions in the binarized image using a region growing algorithm; calculating the geometric feature descriptor of each connected pixel region, the geometric feature descriptor including area, perimeter, and rectangularity; performing similarity matching between the geometric feature descriptor of each connected pixel region and the feature descriptors in a pre-stored feature template library; and determining that an image region conforming to preset morphological characteristics has been detected when the matching similarity of a connected pixel region exceeds a preset similarity threshold.

6. The machine vision-based size measurement and scoring method according to claim 1, characterized in that, The step of calculating the local trajectory complexity index based on the effective measurement point set includes: extracting the spatial coordinates of each location point from the effective measurement point set; fitting the spatial coordinates of all location points into a smooth curve; calculating the variance of the first derivative sequence of the smooth curve, and recording the variance as the intensity of directional change; calculating the average value of the curvature sequence of the smooth curve, and recording the average value as the path curvature; and weighted summing the intensity of directional change and the path curvature to obtain the local trajectory complexity index.

7. The machine vision-based size measurement and scoring method according to claim 1, characterized in that, The steps for calculating the original operational efficiency value include: obtaining a first timestamp corresponding to the start time of the measurement and a second timestamp corresponding to the end time of the measurement; calculating the difference between the second timestamp and the first timestamp to obtain the total time consumption; establishing an efficiency calculation model that includes a sequence deviation factor, a local trajectory complexity index, and total energy consumption; inputting the sequence deviation factor into the first calculation channel of the efficiency calculation model to obtain a sequence penalty component; inputting the local trajectory complexity index into the second calculation channel of the efficiency calculation model to obtain a trajectory normalization component; inputting the total time consumption into the third calculation channel of the efficiency calculation model to obtain a time efficiency component; and performing a synthesis operation on the sequence penalty component, the trajectory normalization component, and the time efficiency component to output the original operational efficiency value.

8. The machine vision-based size measurement and scoring method according to claim 5, characterized in that, The steps of applying binarization segmentation to each video frame include: selecting a global threshold in a specific color space channel of the video frame; comparing the component value of each pixel in the video frame in that color space channel with the global threshold; setting pixels with component values ​​greater than the global threshold as foreground pixels and pixels with component values ​​less than or equal to the global threshold as background pixels; performing a morphological opening operation on the image after setting to remove small noise points in the foreground; and performing a morphological closing operation on the image after performing the morphological opening operation to fill small holes in the foreground, thereby obtaining the final binarized image.

9. The machine vision-based size measurement and scoring method according to claim 6, characterized in that, The step of fitting the spatial coordinates of all location points into a smooth curve includes: using a non-uniform rational B-spline curve fitting method, taking the spatial coordinates of all location points in the effective measurement point set as control points; assigning a weight value to each control point and determining a node vector; generating the parametric equation of the smooth curve based on the control points, the weight value, and the node vector; and calculating the coordinates of a series of densely sampled points on the curve using the parametric equation to characterize the fitted smooth curve.

10. A machine vision-based size measurement and scoring system, comprising a memory, a processor, and a computer program stored in the memory and running on the processor, characterized in that, When the processor executes the computer program, it implements the steps of the machine vision-based size measurement and scoring method according to any one of claims 1 to 9.

Citation Information

Patent Citations

  • Part size detection method based on machine vision

    CN120747194A

  • Clock part size measuring method and system based on machine vision

    CN120931711A