CN103679731B - Arc partition method based on file and picture - Google Patents

Arc partition method based on file and picture Download PDF

Info

Publication number
CN103679731B
CN103679731B CN201310700137.3A CN201310700137A CN103679731B CN 103679731 B CN103679731 B CN 103679731B CN 201310700137 A CN201310700137 A CN 201310700137A CN 103679731 B CN103679731 B CN 103679731B
Authority
CN
China
Prior art keywords
point
points
circle
picture
circular arc
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN201310700137.3A
Other languages
Chinese (zh)
Other versions
CN103679731A (en
Inventor
王轩
张自力
于成龙
李鑫鑫
张加佳
刘猛
赵海楠
李晔
漆舒汉
关键
张江涛
刘博�
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Shenzhen Graduate School Harbin Institute of Technology
Original Assignee
Shenzhen Graduate School Harbin Institute of Technology
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Shenzhen Graduate School Harbin Institute of Technology filed Critical Shenzhen Graduate School Harbin Institute of Technology
Priority to CN201310700137.3A priority Critical patent/CN103679731B/en
Publication of CN103679731A publication Critical patent/CN103679731A/en
Application granted granted Critical
Publication of CN103679731B publication Critical patent/CN103679731B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Landscapes

  • Image Analysis (AREA)

Abstract

The invention provides a kind of arc partition method based on file and picture, comprise the steps: that step 1) determines the parameter of circular arc;Step 2) utilize axis of symmetry aligning step 1) in parameter;Step 3) judges it is complete circle or part circle.The method can improve the vector quantization efficiency of file and picture.For the digitized of paper document, the management of electronic document, and build threedimensional model according to two dimension drawing strong support is provided.

Description

Arc partition method based on file and picture
Technical field
The present invention relates to figure segmentation, particularly relate to the arc fragmenting of file and picture.
Background technology
It is the trend of information age to the vector quantization of file and picture and digitized, and Figure recognition is a key issue in file and picture.As long as can correctly identify that the content of file and picture just can process a lot of file and picture.Circular arc, as a kind of shape the most common in file and picture, is but a difficult point in Figure recognition.Realize arc fragmenting fast and accurately significant to processing file and picture.
Tool nose radius and the difference of arc fragmenting:
Tool nose radius: only need to know that this shape is a complete circle or partly justifies the most permissible.Need not obtain its radius size, central coordinate of circle, and live width.
Arc fragmenting: firstly the need of knowing that this shape is a complete circle or part circle.If complete circle, need accurately to obtain its central coordinate of circle, radius, and live width.If part circle, not only need accurately to obtain its central coordinate of circle, radius, and live width, in addition it is also necessary to accurately obtain start angle and the termination point of this part circle.
In image procossing, Hough transformation is usually utilized to the identification to circular arc, but the segmentation effect of Hough transformation is excessively poor when the content of image is more complicated, and the method time complexity is the highest.The skeleton technique of various improvement is also used to split circular arc, but due to the birth defect of skeleton technique, the effect that these methods split is unsatisfactory.It is, therefore, desirable to provide the method for new segmentation circular arc.
Summary of the invention
The arrival of information age allows the quantity of various resource increase sharply, transmission the most rapidly and efficiently and to store these resources be a problem needing solution badly.Paper document is changed into e-file to build digital library, make it easier to management, store and transmit.By by engineering drawing file, be converted to e-file and can construct threedimensional model.The method that the present invention proposes is exactly the paper document by comprising various figure, and such as architectural drawing, circuit design drawing, electrical design figure etc., the form changing into vector deposits into computer, to facilitate later document management and structure threedimensional model.Wherein the segmentation to circular arc is a difficulties.If circular arc can effectively be split will improve the quality of file and picture vector quantization to a great extent.
In order to solve problem in prior art, the invention provides a kind of arc partition method based on file and picture, comprise the steps:
Step 1) determine the parameter of circular arc:
Firstly the need of finding at least 3 points on circular arc, these points are then utilized to calculate the parameter of circular arc.Its method is as follows: progressive scanning picture, when running into a black pixel point A, with this point as the center of circle, the value utilizing two regular lengths is radius, draw two concentric circulars, regular length herein, selection is the length of two different numerical value, and the two concentric circular obtains at least 3 intersection points with the line segment intersection of surrounding, if only two intersection points, then this A point being given up, continue to scan on, having at least 3 intersection points until meeting;Remove noise spot;Central coordinate of circle and radius is obtained with the retained point including A point;
Step 2) utilize axis of symmetry aligning step 1) in parameter:
Use three line scannings the most simultaneously, using three line scannings, if three scan lines simultaneously suffer black pixel point, and the same straight line at 3 places is all black the most simultaneously, then this line may be exactly an axis of symmetry, is left by the coordinate of this axis of symmetry;
Integrating step 1) information of circular parameters tried to achieve, if it is less, then with the coordinate that this coordinate replacement central coordinate of circle is corresponding to try to achieve error when the coordinate of certain axis of symmetry is substituted into equation of a circle;
Step 3) judge it is complete circle or part circle:
According to fixed angle and meet the principle of equation of a circle to generate some points, judge the pixel value of these points the most again:
Use the strategy only generating part point, and by these some distributions circumferentially, if these are all black picture elements, then this circular arc is exactly complete circle;If being black picture element with regard to a part in these points, then this circular arc is part circle, needs to obtain its start angle and termination point further.
As a further improvement on the present invention, step 1) eliminate noise spot method as follows:
The first strategy is to remove these noise spots according to live width:
In a line or circular arc, if the live width at the live width at these intersection point places and A point place is different, then these points are removed;
The second strategy is to utilize seriality to remove noise spot:
Expanding to both sides with A for source point, if the point newly added and the line segment that point was formed in the past are not holomelanocratic points, the point newly added must go to remove, and otherwise can retain this point newly added;
The third strategy be utilize and the straight line that is linked to be of two intersection points that inner circle is formed must A point and and the intersection point of cylindrical between;
The intersection point the most simultaneously meeting three of the above strategy just can be retained when.
Handled image is bianry image, and background is white, and prospect is black.
As a further improvement on the present invention, step 2) in, in three lines, if the length of image to be scanned or width are L, a middle scan line is at L/2.
As a further improvement on the present invention, step 3) in, obtain its start angle and termination point further, method is as follows: first obtain white pixel and the separation of black picture element on circumference, this separation is a relatively coarse value, needing again to generate intensive point near this is put, the value tried to achieve again is only start angle or the termination point of this circular arc.
As a further improvement on the present invention, step 3) in, fixing angle is as follows: the angle value scope between adjacent two points is 360/5.6R to 360/5.7R, and R is radius, and with the number of pixel as length, angle takes Circular measure.
The invention has the beneficial effects as follows:
The method can improve the vector quantization efficiency of file and picture.For the digitized of paper document, the management of electronic document, and build threedimensional model according to two dimension drawing strong support is provided.
Detailed description of the invention
This method mainly includes the content of three aspects:
1) parameter of circular arc, i.e. central coordinate of circle and radius are determined;
2) utilize axis of symmetry to correct these parameters;
3) on circular arc, generate a series of point, and judge that the circular arc at these places is complete circle or partly justifies.
The image of all process is all bianry image, and background is white, and prospect is black.
1) parameter of circular arc is determined
3 thoughts that may determine that an equation of a circle according to not conllinear, it is necessary first to find several point, then utilize these points to calculate the parameter of circular arc.Concrete grammar is as follows: progressive scanning picture, when running into a black pixel point A, with this point as the center of circle, the value utilizing two regular lengths is radius, draw two concentric circulars, regular length herein, selection is the length of two different numerical value, the determination of the size of length, person of ordinary skill in the field is adjusted according to resolution and the experience of image and determines.The two concentric circular obtains several intersection point with the line segment intersection of surrounding, is generally four intersection points, needs three intersection points at least.Illustrate: if only two intersection points, then given up by this A point, continue to scan on have at least 3 intersection points until meeting.Convenience in order to calculate only uses two concentric circulars to find intersection.In order to improve accuracy rate as far as possible, calculate the number of point of Circle Parameters more preferably greater than three.During this is asked a little, can be potentially encountered a lot of noise spot.The present invention uses three kinds of strategies to eliminate these noise spots.The first strategy is to remove these noise spots according to live width.In a line or circular arc, the live width at each place should be equal, if the live width at the live width at these intersection point places and A point place is different, is then removed by these points.The second strategy is to utilize seriality to remove noise spot.In piece image, different lines or circular arc are likely to be identical live width, but these intersection points are not to be on the same line or circular arc with A.Must be the principle of continuous black picture element according to the line segment between consecutive points, expand to both sides for source point with A, if the point newly added and the line segment that point was formed in the past are not holomelanocratic points, the point newly added must go to remove, and otherwise can retain this point newly added.The third strategy be utilize and the straight line that is linked to be of two intersection points that inner circle is formed must A point and and the intersection point of cylindrical between.The intersection point the most simultaneously meeting these three strategy just can be retained when.The point retained with these (including A points) obtains central coordinate of circle and radius.
2) axis of symmetry is utilized to be corrected
3 thoughts that may determine that a circle according to not conllinear, three points of conllinear are not to may determine that an equation of a circle, but these three point not necessarily may determine that a unique circle, and due to pixel error, close 3 points of computed range may obtain multiple circle.Owing to, seeking Circle Parameters when, concentrically ringed radius is fixing, and it cannot be guaranteed that enough big of the distance of these intersection points, to such an extent as to it is not the most accurate for trying to achieve Circle Parameters.When what relation the relative position of these intersection points meet when, the Circle Parameters tried to achieve is only the most accurately.Being found through experiments, the circular arc formed when three points is half bowlder, and the Circle Parameters tried to achieve is more accurately.But in actual operation, wanting to allow the position distribution of these three point is unpractical on semicircle.It is thus desirable to utilize information around to correct these parameter values.By analyzing these drawings, find axis of symmetry be prevalent in drawing, these axis of symmetry the most all through the center of circle, and be all horizontal symmetry axis and vertical axis of symmetry in the majority, so utilizing the information of axis of symmetry can correct these parameters.Owing to part figure does not has axis of symmetry, or there is Local Symmetric axle in certain local of figure.These situations comprehensive, from the point of view of time and efficiency, use three line scannings the most simultaneously, use three line scannings the most simultaneously, the abscissa being the most i.e. scanned plane herein and vertical coordinate direction, if three scan lines simultaneously suffer black pixel point, and the same straight line at 3 places is all black, then this line may be exactly an axis of symmetry, is left by the coordinate of this axis of symmetry.Article three, in line, if the length of image to be scanned or width are L, a middle scan line is at L/2.Use same method, until the most all having scanned.In conjunction with the information of the circular parameters tried to achieve above, if it is less to try to achieve error when the coordinate of certain axis of symmetry is substituted into equation of a circle, then this coordinate is can use to replace the coordinate that central coordinate of circle is corresponding.
3) judge it is complete circle or part circle
Owing to part circle also needs to obtain its start angle and termination point, so needing to judge that this section of circular arc is belonging to complete circle and still falls within part circle.Some research worker uses classical Bresenham (literal translation: Bo Ruisen Durham) picture circle method to carry out " redrawing " this circular arc.Present invention experimental verification show that the efficiency of the method has much room for improvement.The pixel that there is a lot of redundancy in the circular arc that circle method draws is drawn by Bresenham.When needs judge, in advance all pixels on circumference are deposited in an array according to the order of angular dimension, when needing the next point found on circular arc, it is accomplished by scanning this array, adjacent pixel value is the most all to have same angular angle value, in order to obtain the pixel of a different angle, it is necessary for judging one by one the pixel of equal angular.When the radius of circular arc is the biggest, need the redundant points judged the most.Because the angle that circumference is corresponding is all 360 degree, radius is the biggest, and corresponding circumference is the longest, and on circumference, the number of point is the most.The method that the present invention uses is " judgement " these points, if the coordinate that certain point is black picture element and this point meets equation of a circle, then this point is the most circumferentially.During beginning, the present invention is randomly generated some points, present invention discover that these random points can produce some mistakes in experiment later.Then the present invention generates some points according to fixed angle (computational methods explanation sees below), judges the pixel value of these points the most again.In order to improve efficiency, the present invention can only generate a part of point.If these are all black picture elements, then this circular arc is exactly complete circle;If being black picture element with regard to a part in these points, then this circular arc is part circle, needs to obtain its start angle and termination point further.First obtaining white pixel and the separation of black picture element on circumference, this separation is a relatively coarse value, needs again to generate intensive point near this is put, and the value tried to achieve again is only start angle or the termination point of this circular arc.
The computational methods of fixed angle are as follows: obtain the size of radius and the relation of the number of point on circumference by experiment, such as table 1 below.Such as, if radius R is 10 length in pixels, then having 56 points on this circumference, the angle value of these points is the most different.When obtaining the radius of certain circular arc, just find out radius value relatively according to the following table, then obtain the number of point on the circumference of correspondence.360 divided by this number, it is simply that fixing angle, the angle value (Circular measure) between the most adjacent two points.
The relation of the number of point in table 1 radius size and circumference
Above content is to combine concrete preferred implementation further description made for the present invention, it is impossible to assert the present invention be embodied as be confined to these explanations.For general technical staff of the technical field of the invention, without departing from the inventive concept of the premise, it is also possible to make some simple deduction or replace, all should be considered as belonging to protection scope of the present invention.

Claims (5)

1. an arc partition method based on file and picture, it is characterised in that comprise the steps:
Step 1) determines the parameter of circular arc:
Firstly the need of finding at least 3 points on circular arc, then these points are utilized to calculate the parameter of circular arc, progressive scanning picture, when running into a black pixel point A, with this black pixel point A as the center of circle, the value utilizing two regular lengths is radius, draw two concentric circulars, regular length herein, selection is the length of two different numerical value, and the two concentric circular obtains at least 3 intersection points with the line segment intersection of surrounding, if only two intersection points, then this A point being given up, continue to scan on, having at least 3 intersection points until meeting;Remove noise spot;Central coordinate of circle and radius is obtained with the retained point including A point;
Step 2) utilize axis of symmetry aligning step 1) in parameter:
Use three line scannings the most simultaneously, using three line scannings, if three scan lines simultaneously suffer black pixel point, and the same straight line at 3 places is all black the most simultaneously, then this line may be exactly an axis of symmetry, is left by the coordinate of this axis of symmetry;
Integrating step 1) information of circular parameters tried to achieve, if it is less, then with the coordinate that this coordinate replacement central coordinate of circle is corresponding to try to achieve error when the coordinate of certain axis of symmetry is substituted into equation of a circle;
Step 3) judges it is complete circle or part circle:
According to fixed angle and meet the principle of equation of a circle to generate some points, judge the pixel value of these points the most again:
Using the strategy only generating part point, and be distributed on circumference by these points, if these are all black picture elements, then this circular arc is exactly complete circle;If being black picture element with regard to a part in these points, then this circular arc is part circle, needs to obtain its start angle and termination point further.
Arc partition method based on file and picture the most according to claim 1, it is characterised in that: it is as follows that step 1) eliminates noise spot method:
The first strategy is to remove these noise spots according to live width:
In a line or circular arc, if the live width at the live width at these intersection point places and A point place is different, then these points are removed;
The second strategy is to utilize seriality to remove noise spot:
Expanding to both sides with A for source point, if the point newly added and the line segment that point was formed in the past are not holomelanocratic points, the point newly added must go to remove, and otherwise can retain this point newly added;
The third strategy be utilize and the straight line that is linked to be of two intersection points that inner circle is formed must A point and and the intersection point of cylindrical between;
The intersection point the most simultaneously meeting three of the above strategy just can be retained when.
Arc partition method based on file and picture the most according to claim 1, it is characterised in that: handled image is bianry image, and background is white, and prospect is black.
Arc partition method based on file and picture the most according to claim 1, it is characterized in that: in step 3), obtain its start angle and termination point further, method is as follows: first obtain white pixel and the separation of black picture element on circumference, this separation is a relatively coarse value, needing again to generate intensive point near this is put, the value tried to achieve again is only start angle or the termination point of this circular arc.
Arc partition method based on file and picture the most according to claim 1, it is characterized in that: in step 3), fixing angle is as follows: the angle value scope between adjacent two points is 360/5.6R to 360/5.7R, and R is radius, with the number of pixel as length, angle takes Circular measure.
CN201310700137.3A 2013-12-18 2013-12-18 Arc partition method based on file and picture Active CN103679731B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201310700137.3A CN103679731B (en) 2013-12-18 2013-12-18 Arc partition method based on file and picture

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201310700137.3A CN103679731B (en) 2013-12-18 2013-12-18 Arc partition method based on file and picture

Publications (2)

Publication Number Publication Date
CN103679731A CN103679731A (en) 2014-03-26
CN103679731B true CN103679731B (en) 2016-12-07

Family

ID=50317182

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201310700137.3A Active CN103679731B (en) 2013-12-18 2013-12-18 Arc partition method based on file and picture

Country Status (1)

Country Link
CN (1) CN103679731B (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108133499B (en) * 2017-11-16 2023-08-01 李名雪 Conversion method of bitmap and CAD/CAM vector diagram

Citations (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103425988A (en) * 2013-07-03 2013-12-04 江南大学 Real-time positioning and matching method with arc geometric primitives

Family Cites Families (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPS6219989A (en) * 1985-07-18 1987-01-28 Fuji Electric Co Ltd Discrimination method for superposed pattern
AU2011253779A1 (en) * 2011-12-01 2013-06-20 Canon Kabushiki Kaisha Estimation of shift and small image distortion

Patent Citations (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103425988A (en) * 2013-07-03 2013-12-04 江南大学 Real-time positioning and matching method with arc geometric primitives

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
"机械零件图纸的矢量化及拼接技术研究";姬忠校;《中国优秀硕士学位论文全文数据库(信息科技辑)》;20080915(第9期);第24-45页 *

Also Published As

Publication number Publication date
CN103679731A (en) 2014-03-26

Similar Documents

Publication Publication Date Title
CN110349252A (en) A method of small curvature part actual processing curve is constructed based on point cloud boundary
CN101303768B (en) Method for correcting circle center error of circular index point when translating camera perspective projection
CN101819680B (en) Detection method of picture matching point pair
US20160239975A1 (en) Highly robust mark point decoding method and system
CN105023014B (en) A kind of shaft tower target extraction method in unmanned plane inspection transmission line of electricity image
CN108573511B (en) Point-distributed cooperative coding mark and identification and positioning method thereof
CN108053477B (en) Numerical processing method for deformation in pipeline
CN110853081B (en) Ground and airborne LiDAR point cloud registration method based on single-tree segmentation
CN103530889A (en) Method for decoding coding mark points of measuring stick based on skeleton extraction
US9613398B2 (en) Image descriptor and method of pattern recognition
CN102081748B (en) Bar code pattern and bar code group pattern formed by node matrix and node line, and generation and identification method thereof
CN102446356A (en) Parallel and adaptive matching method for acquiring remote sensing images with homogeneously-distributed matched points
CN102881028A (en) Method for quickly vectorizing grid digital image
CN103679731B (en) Arc partition method based on file and picture
CN115222883A (en) Electric power tower reconstruction method based on foundation LiDAR point cloud
CN102074011A (en) Method for detecting oblique triangle in digital image
CN101916381A (en) Object contour extraction method based on sparse representation
CN106446499A (en) Three-dimensional chain code-based space curve identification method
CN110567395B (en) Laser spot size edge contour line drawing method
CN106780577B (en) A kind of matching line segments method based on group feature
CN111461032A (en) Inclined image straight line feature matching method based on local structure and topological geometric constraint
CN109827504B (en) Machine vision-based steel coil end face local radial detection method
CN104809460B (en) Germ nucleus position drawing generating method and transistor pixel search table generating method
CN106199745A (en) A kind of recognition methods of the pore throat of connection
CN115143936B (en) Method for measuring gradient of power transmission engineering pole tower based on laser point cloud

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
C14 Grant of patent or utility model
GR01 Patent grant