Background technology
In today that PC is popularized day by day, the CAD electronic drawing is widely used in numerous areas such as building, design, manufacturing, and most typical example is exactly AutoCAD.Such a electronic drawing has only been expressed the most general geological information usually, can not satisfy the professional domain demand.With the building field is example, and AutoCAD just adds label character with geometric graphic elements such as point, line, surface to building element (wall, beam, post etc.) and describes, and does not express specialty and calculates information such as needed three-dimensional body, reinforcing bar, template.So, the concrete model from general electronic drawing to professional domain, the centre all needs one " translation " process of " identification " in other words.Translation is in the past all accomplished by manual work: on one side the technician knows figure, Yi Bian use the professional software modeling.If have software can accomplish this type of translation automatically, then can greatly raise the efficiency undoubtedly.
Occurred some engineering drawing identifying schemes in the prior art, its core concept is all based on the computer patterns identification thinking with the combination of artificial auxiliary phase.The most frequently used method is to let user's model of on electronic drawing, having indicated which information description, has represented the geometric configuration of model such as which pel of indication, and which label character has been described the character of model.Computing machine goes information such as pel that analysis user selects, literal automatically then, finally builds out model.This identifying schemes can be realized the purpose of Intelligent Recognition to a certain extent, but all more or less has certain defective, is mainly reflected in following three aspects:
(1) recognition accuracy is lower.Prior art lets the indication of disposable all information of completion of user, lets the processing of the disposable completion corresponding model of computing machine again.With the building element shear wall is example, and prior art lets disposable current layer all wall line, the mark chosen of user, all shear walls of the disposable identification current layer of computing machine then.Because mutual rule is single, the prior imformation that software can utilize is not enough, makes the recognition result height depend on algorithm; Because the lack of standard of drawing causes algorithm when analyzing, to face considerable loss of learning, it is up to standard to make that last recognition accuracy is difficult to again.
(2) recognition efficiency is on the low side.Because be disposable identification, period of reservation of number is longer, influences experience.
(3) verification is inconvenient.For the recognition result of mistake, the user lacks the effective means fast processing, and final recognition result correctness needs a lot of desk checkings, and practicality is not enough.
In fact, present industrial numerous areas (such as building, design, machine-building) all has such demand: according to the information of CAD electronic drawing, member goes out the member of professional domain demand, but prior art can not satisfy these requirements.Thereby the present invention is based on and mainly solve under this type of current demand, a kind of completely new approach of the quick identification modeling based on the CAD electronic drawing is proposed.
Summary of the invention
To the problem that exists in the prior art, the object of the present invention is to provide a kind of dynamic component recognition methods based on the CAD electronic drawing, it helps to improve recognition efficiency, accuracy rate, and makes things convenient for verification.
For solving above technical matters, technical scheme provided by the invention is: a kind of method of the accurate identification dynamic component based on the CAD electronic drawing,
(1) obtains the 2-D data of extracting thing on the CAD electronic drawing;
(2) on the CAD drawing, confirm a close neighborhood according to the 2-D data that grasps thing;
(3) in close neighborhood, search all candidate's primitive information;
(3) all primitive information of searching are sorted.
Said extracting thing is to confirm through the media that is used for man-machine interaction, and said media comprises keyboard, mouse and touch-screen.
Said extracting thing is the current position of media, gets access to two-dimensional coordinate corresponding on the CAD electronic drawing according to the current position of media.
The ordering of said primitive information is sorted through candidate's primitive information and the 2-D data that grasps thing.
Said extracting thing is the motion track of media, obtains on the CAD electronic drawing and corresponding all two-dimensional coordinates of media motion track according to the motion track that grasps thing.
The ordering of said primitive information is that the motion track through the information of candidate's pel and media carries out.
Said close neighborhood is according to the 2-D data that grasps on the CAD electronic drawing of thing place, and on the CAD electronic drawing around the said 2-D data, draws and get that certain scope realizes.
The mode of searching of said close neighborhood is from inside to outside, from outside to inside, from left to right, from right to left, from top to bottom and from top to bottom in the mode any searched.
Said through candidate's primitive information is sorted, all primitive information are appeared to difference from excellent one by one, be used for the client and select needed primitive information.
Said through candidate's primitive information is sorted, the result that selection is optimum is used to feed back to the client.
Compared with prior art, the dynamic component recognition methods that the present invention is based on the CAD electronic drawing has proposed a kind of recognition technology of dynamic component efficiently, and it can not only promote the accuracy rate of identification; And What You See Is What You Get, through feeding back to the user to recognition result in real time, the user only need make a strategic decision to recognition result; Select correct result; The result who ignores mistake, thereby processing and identification result apace bring better experience.Because the user has carried out verification in identifying, thereby helps to simplify down-stream, also helps to increase work efficiency.
Embodiment
Core of the present invention is, dynamic component identification, and according to the current location of media, information such as the historical track of media dynamically identify the member of professional domain in real time.The position is different, and track is different, and recognition result is also inequality.
In order to make those skilled in the art understand technical scheme of the present invention better, the present invention is done further detailed description below in conjunction with accompanying drawing and specific embodiment.
A kind of method of the accurate identification dynamic component based on the CAD electronic drawing includes but not limited to following steps:
1, obtains the 2-D data of extracting thing on the CAD electronic drawing;
Said extracting thing is through comprising that the media that keyboard, mouse and touch-screen etc. are used for man-machine interaction confirms; Get access to the historical information of said extracting thing on the CAD electronic drawing through data such as current position of media or motion tracks, confirm to grasp the 2-D data of thing on the CAD electronic drawing according to the historical data that grasps thing then.
2, on the CAD electronic drawing, confirm a close neighborhood according to the 2-D data that grasps thing;
According to grasping the 2-D data of thing on the CAD electronic drawing; Around said 2-D data, draw certain scope of getting then; The scope that this stroke got promptly is close neighborhood, and the drawing of said scope got and to confirm in the both sides up and down of its X axle left and right sides and Y axle through the 2-D data that grasps thing.
3, in close neighborhood, search all candidate's primitive information;
Said close neighborhood obtains; In close neighborhood, search the information of all candidate's pels then, the said mode of searching is the center to grasp thing generally, then according to similar graph traversal algorithm; Expansion successively from inside to outside is till can't finding more candidate's pel and text description.The said mode of searching comprises also that from outside to inside expansion successively, expansion successively from top to bottom, expansion successively from top to bottom, from left to right expansion successively, expansion successively from right to left etc. search mode.
4, all primitive information of searching are sorted.
According to the information of all candidate's pels of searching, according to candidate's pel and text description, and the historical track information of mouse waits all candidate's pels are sorted.
Referring to Fig. 1, the idiographic flow of facing the dynamic component recognition methods that the present invention is based on the CAD electronic drawing down carries out detailed explanation, and is specific as follows:
S101, the historical information of searching the extracting thing:
Said extracting thing is through comprising that the media that keyboard, mouse and touch-screen etc. are used for man-machine interaction confirms, information such as motion track through media or current position are obtained and grasped the historical information of thing on the CAD electronic drawing.
S102, obtain the 2-D data that grasps thing:
According to grasping the historical information of thing on the CAD electronic drawing, confirmed extracting thing residing position on the CAD electronic drawing, get access to the 2-D data of extracting thing on the CAD electronic drawing in the position of CAD electronic drawing according to grasping thing then.
S103, confirm to comprise the close neighborhood that grasps thing:
According to grasping the 2-D data of thing on the CAD electronic drawing, on the CAD electronic drawing around the said 2-D data, draw certain scope of getting, this scope is exactly to grasp the close neighborhood of thing.
S104, search the primitive information in the close neighborhood:
According to the close neighborhood of confirming, in close neighborhood, search all candidate's primitive information, till searching less than next primitive information.The said general similar graph traversal algorithm of mode of searching; Expansion successively from inside to outside; Till can't finding more candidate's pel and text description, the said mode of searching comprises also that from outside to inside expansion successively, expansion successively from top to bottom, expansion successively from top to bottom, from left to right expansion successively, expansion successively from right to left etc. search mode.
S105, all candidates' primitive information is sorted:
The primitive information that finds all candidates is sorted to it according to historical track information of candidate's pel, text description and media etc.
The result of S106, feedback ordering:
Because above-mentioned primitive information to the candidate sorts, the result that will sort then feeds back to the client.The ranking results of said feedback comprises that the result with ordering feeds back to the client from excellent to difference one by one; By the needed primitive information of customer selecting; Further only extract primitive information optimum in the ranking results and feed back to the client, determine to adopt or abandon said recognition result by the user.
Above said dynamic component recognition methods and flow process based on the CAD electronic drawing; Confirm close neighborhood through grasping the 2-D data of thing on the CAD electronic drawing; In neighborhood, search all candidate's primitive information then; And all primitive information are sorted, at last the result is fed back to the user, make things convenient for the user to select.Because ordering is to sort according to the historical track information of candidate's pel, text description and media etc., thereby improved the discrimination of pel when having improved the accuracy that candidate's pel chooses; The present invention is as long as move media in addition, and the result of ordering also changes naturally thereupon like this, and more convenient like this user chooses needed primitive information, and the school inspection is convenient.
The media of common now man-machine interaction comprises keyboard, mouse (being shown in the PC computer) and touch-screen (being shown in panel computer).Under the occasion of member identification, the user mainly sends prior imformation through mouse and touch-screen to computer, auxiliary engine identification.Because the method for operating of these two kinds of media similar (move, click),, repeat no more so all to unify with the mouse be representative to hereinafter.
Below be the application example that utilizes mouse Dynamic Recognition CAD electronic drawing member, the information that it has made full use of mouse comprises mouse current location and mouse historical track, specifically comprises following key step;
1, (x, y) as shown in Figure 2, wherein the P point is the small particles among Fig. 2 at first to obtain 2 dimensions point P corresponding on the electronic drawing according to the mouse current location.
The coordinate of 2, ordering according to P is chosen the close neighborhood that appropriate scope is ordered as P on the CAD electronic drawing around the P point; In said close neighborhood, search all candidate's pel and text description; The similar graph traversal algorithm of said search procedure; Expansion successively from inside to outside is till can't finding more candidate's pel and text description.Specifically as shown in Figure 3, wherein in the p neighborhood of a point, progressively expand outwardly, search candidate's pel and text description, curvilinear frame is lived part among result such as Fig. 3.
3, according to candidate's pel and text description, and the information such as historical track of mouse, identify optimal result, feed back to the user in real time, and determine to adopt or abandon recognition result by the user.Referring to Fig. 4, identify optimal result like " cross " solid section based on candidate information.
The above-mentioned application example that utilizes mouse Dynamic Recognition CAD electronic drawing member, according to the current location of mouse, information such as mouse historical track dynamically identify the member of professional domain in real time.The position is different, and track is different, and recognition result is also inequality; Be dynamic component identification, What You See Is What You Get feeds back to the user to recognition result in real time; The user only need determine to adopt or refuse current recognition result; The user only need make a strategic decision to recognition result, thereby processing and identification result apace brings better experience.
In like manner; Utilize the media communication of man-machine interactions such as keyboard and touch-screen, find the 2-D data of said media correspondence on the CAD electronic drawing, confirm close neighborhood then; And in close neighborhood, search all candidate's primitive information; And the primitive information to all sorts, and ranking results is fed back to the client in real time, confirms operation by the client.
In sum; Dynamic component recognition methods based on the CAD electronic drawing of the present invention, the media that is used for man-machine interaction through utilization confirms to grasp the historical information of thing, obtains grasping thing corresponding 2-D data on the CAD electronic drawing according to the historical information that grasps thing; And confirm a close neighborhood that grasps thing at the CAD electronic drawing according to described 2-D data; In close neighborhood, search candidate's primitive information through certain mode then, till can't finding the next one, and all candidate's primitive information are sorted; The result that preferably will sort feeds back to the client, is operated accordingly by the client.According to the current location that grasps thing, information such as extracting thing historical track dynamically identify the member of professional domain in real time.The position is different, and track is different, and recognition result is also inequality, i.e. dynamic component identification, and What You See Is What You Get has improved pel identification efficiency and the inspection of convenient school; Said in addition close neighborhood is to confirm through the 2-D data that grasps thing, and candidate's primitive information finds out in close neighborhood, has improved the accuracy rate of pel identification like this.
Only be preferred implementation of the present invention below, should be pointed out that above-mentioned preferred implementation should not be regarded as limitation of the present invention, protection scope of the present invention should be as the criterion with claim institute restricted portion.For those skilled in the art, do not breaking away from the spirit and scope of the present invention, can also make some improvement and retouching, these improvement and retouching also should be regarded as protection scope of the present invention.