Industrial three-dimensional drawing retrieval generation method and system based on difference dimension control
By extracting multidimensional difference features and generating difference dimension subspace representations, combined with user control conditions, dynamic decoupling and adaptation of industrial 3D drawing retrieval are achieved. This solves the problems of low retrieval efficiency and insufficient adaptability of feature differences in existing technologies, and improves the flexibility and accuracy of retrieval.
Patent Information
- Application Number
- CN202611361057.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-09-03
- Publication Date
- 2026-11-27
AI Technical Summary
Existing industrial 3D drawing retrieval methods rely on static feature comparison, which cannot decouple the multi-dimensional structural features of parts. This results in low retrieval efficiency and an inability to meet the specific feature differences required in complex engineering scenarios, as well as an inability to adapt to the differentiated needs of different positions.
By extracting multidimensional difference features, generating difference dimension subspace representations, and combining user difference control conditions, a masked difference similarity calculation is adopted to achieve dynamic retrieval and feature decoupling, generating conditional query representations that adapt to user intent.
It improves the flexibility and matching accuracy of the retrieval process, ensures that the retrieval results meet expectations, adapts to the differentiated needs of different engineering positions, and avoids erroneous filtering problems caused by inconsistencies in local details.
Smart Images

Figure CN123178663A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of data processing technology, and in particular to a method and system for retrieving and generating industrial 3D drawings based on differential dimension control. Background Technology
[0002] With the rapid development of intelligent manufacturing, the reuse of industrial computer-aided design (CAD) models has become a key aspect for enterprises to shorten R&D cycles and reduce design costs. Engineers often need to search through massive historical databases for similar 3D drawings for reference design or process evaluation.
[0003] In practice, early drawing retrieval relied primarily on manually maintained material codes, file names, or text tags. This approach not only consumed significant manual labor costs but also heavily depended on personal experience, failing to accurately represent the complex geometry, boundary representation (B-Rep) topology, and local manufacturing features of 3D models. Consequently, retrieval efficiency was low, and missed detections were common.
[0004] To overcome the limitations of text retrieval, automated retrieval tools based on 3D geometric features have gradually emerged in existing technologies. However, these tools have significant technical limitations. First, most of them employ a single global similarity evaluation mechanism, such as mapping point clouds or mesh models to a single global feature vector for distance comparison. This method cannot decouple the main body shape, local features, tolerance parameters, and other multi-dimensional features of a part, resulting in inaccurate judgments of the overall semantics of the model. Second, in actual engineering tasks, different positions have vastly different definitions of "similarity." For example, process engineers may only focus on the hole arrangement while ignoring differences in the main body shape, and existing static similarity calculations cannot adapt to these dynamic differences and preferences. Furthermore, when faced with homogeneous parts that have undergone local modifications (such as adding chamfers or adjusting interfaces), existing systems struggle to perform targeted feature masking or hard constraints, leading to deviations between the output results and the user's actual reuse requirements.
[0005] In summary, existing industrial 3D drawing retrieval methods rely on static feature comparison and have low levels of intelligence, failing to meet the needs of targeted control of specific feature differences in complex engineering scenarios, resulting in low utilization of historical drawing resources. Therefore, there is an urgent need for a retrieval technology solution that can understand multi-dimensional structural features and support dynamic interactive control by users. Summary of the Invention
[0006] This invention provides a method and system for retrieving and generating industrial 3D drawings based on difference dimension control, which solves the problems of fixed retrieval similarity definition and lack of user intent control in the prior art.
[0007] The first aspect of this invention proposes a method for retrieving and generating industrial 3D drawings based on difference dimension control, comprising the following steps: The initial query input of the industrial 3D drawing is obtained, multi-dimensional difference features are extracted from the initial query input, and the multi-dimensional difference features are parsed to generate the initial query representation. The initial query representation includes multiple difference dimension subspace representations formed by the independent encoding of each multi-dimensional difference feature. Receive user-differentiated control conditions for industrial 3D drawings, standardize the user-differentiated control conditions into a unified control representation, and use the unified control representation to quantify the control logic of the differential dimension subspace representation. Based on the unified control representation, conditional rewriting is performed on the differential dimension subspace representation to update the initial query representation and generate a conditional query representation. Based on unified control representation and conditional query representation, candidate recall is performed in a pre-set industrial 3D drawing database to obtain candidate parts, and masked difference similarity calculation is performed on the candidate parts to generate a search result sequence.
[0008] In one alternative implementation, the steps of extracting multidimensional difference features from the initial query input and parsing the multidimensional difference features to generate the initial query representation specifically include: Extract the main geometric contour features, boundary representation topology features, local manufacturing features, assembly interface features, parameter dimension features, tolerance and datum features, material and process property features, and historical business property features from the initial query input as various multidimensional difference features; Each multidimensional difference feature is independently encoded to generate a corresponding feature sub-vector; By combining the feature vectors, multiple differential dimension subspace representations are constructed.
[0009] In one alternative implementation, the step of normalizing user-differentiated control conditions into a unified control representation specifically includes: The triggered user-differentiated control conditions are parsed and converted into a unified control representation consisting of multiple control parameters; The unified control representation includes: dimension weights for characterizing the degree of influence of each differential dimension subspace representation, dimension masks for determining whether each differential dimension subspace representation participates in the calculation, a set of hard constraints for strictly filtering candidate parts, and a set of variable range thresholds for defining the tolerance range of parameter fluctuations.
[0010] In one alternative implementation, the step of performing conditional rewriting on the representation of the difference dimension subspace to update the initial query representation, based on the unified control representation, to generate the conditional query representation specifically includes: Based on the dimension mask in the unified control representation, for dimension masks that are in an inactive state, their corresponding differential dimension subspace representations are masked during the rewriting process; Based on the dimension weights in the unified control representation, the corresponding differential dimension subspace representations are subjected to gain amplification or weight reduction processing using the dimension weights. Based on the set of hard constraints in the unified control representation, for the constraints that exist in the set of hard constraints, add hard constraint labels to the corresponding differential dimension subspace representations; By fusing the representations of the various differential dimension subspaces after masking, gain amplification or weight reduction, and additional hard constraint labeling, a conditional query representation is generated.
[0011] In one optional implementation, based on a unified control representation and conditional query representation, the steps of performing candidate recall in a pre-set industrial 3D drawing database to obtain candidate parts, and performing masked difference similarity calculation on the candidate parts to generate a search result sequence specifically include: Using the set of hard constraints in the unified control representation, multiple 3D parts stored in the industrial 3D drawing database are filtered, and the parts that meet the conditions of the hard constraint set are retained to form an initial candidate part set. Conditional vector recall is performed on the parts in the initial candidate part set using conditional query representation to obtain a coarse-ranked candidate part list, and the parts in the coarse-ranked candidate part list are used as candidate parts. Perform masked difference similarity calculation on each candidate part to obtain the comprehensive similarity score between the initial query input and each candidate part; The candidate parts are sorted according to the comprehensive similarity score to generate the final search result sequence.
[0012] In one optional implementation, the step of performing masked difference similarity calculation on each candidate part to obtain a comprehensive similarity score between the initial query input and each candidate part specifically includes: Calculate the local similarity between the subspace representations of each difference dimension in the conditional query representation and the corresponding features of the candidate parts; Multiply each local similarity with the corresponding dimension weight and dimension mask in the unified control representation to obtain the weighted similarity contribution value of each differential dimension subspace representation. The system detects whether the parameter characteristics of candidate parts exceed the variable range threshold set or violate the hard constraint set in the unified control representation. It calculates the violation penalty item based on the exceeded feature range or violated constraint condition, and obtains the total penalty value by combining the preset penalty intensity coefficient. The weighted similarity contribution values of all difference dimension subspaces are summed, and the total penalty value is subtracted from the summation result to obtain the comprehensive similarity score.
[0013] In one alternative implementation, after generating the sequence of search results, the method further includes multiple rounds of interactive feedback and preference convergence steps: Receive interactive feedback information submitted by users for the search result sequence. The interactive feedback information includes retention operations, deletion operations, or reason annotation information for specific candidate parts or specific multidimensional difference features. The unified control representation is dynamically adjusted based on interactive feedback information. Based on the adjusted unified control representation, the conditional query representation is regenerated, and a new round of candidate recall and masked difference similarity calculation is performed based on the updated conditional query representation until the new round of retrieval result sequence meets the user's convergence preference. The unified control representation at which convergence preference is achieved is saved as a historical preference template for use in subsequent retrieval tasks.
[0014] In one alternative implementation, the step of generating the search result sequence also includes a dimensional explanation output step: When outputting the search results sequence containing each candidate part, dimensional explanation information corresponding to each candidate part is generated and displayed synchronously. Dimensional explanation information is generated based on the comparison results of the initial query representation, the features of each candidate part, and the unified control representation; The dimensional explanation information includes: matching dimension descriptions that indicate a high similarity match between the candidate part and the initial query input; ignored dimension descriptions that have been masked according to the dimension mask; conflicting dimension descriptions that lead to a decrease in similarity due to violations of hard constraint sets; and three-dimensional geometric modification suggestions for multi-dimensional difference features in response to conflicts.
[0015] In one alternative implementation, the steps of extracting multidimensional differential features and generating an initial query representation are performed by a pre-trained retrieval network model; the method also includes a pre-training step of the retrieval network model before obtaining the initial query input of the industrial 3D drawing. Construct positive and negative sample pairs for industrial 3D drawings. Positive sample pairs include part samples that have variations in negligible differences but are the same in the core structure. Negative sample pairs include difficult negative samples that conflict in key constraint differences but are similar in the overall outer contour. Positive and negative sample pairs are input into the retrieval network model to be trained, and different preset control conditions are applied during the training process to supervise different similarity targets; By training the retrieval network model based on contrastive learning, the retrieval network model is equipped with the decoupled encoding ability to separate ignorable differences and extract key constraint conflict features.
[0016] A second aspect of this invention provides an industrial 3D drawing retrieval and generation system based on difference dimension control, comprising multiple functional modules for executing the industrial 3D drawing retrieval and generation method based on difference dimension control as proposed in the foregoing embodiments, and including the following interconnected modules: The query input parsing module is used to obtain the initial query input of industrial 3D drawings, extract multidimensional difference features from the initial query input, parse the multidimensional difference features to generate the initial query representation, and the initial query representation includes multiple difference dimension subspace representations formed by the independent encoding of each multidimensional difference feature. The user control standardization module is used to receive user-differentiated control conditions for industrial 3D drawings, standardize the user-differentiated control conditions into a unified control representation, and use the unified control representation to quantify the control logic represented by the difference dimension subspace. The query rewrite generation module is used to perform conditional rewriting on the representation of the differential dimension subspace based on the unified control representation to update the initial query representation and generate a conditional query representation. The retrieval, sorting, and output module is used to perform candidate recall in a preset industrial 3D drawing database to obtain candidate parts based on a unified control representation and conditional query representation, and to perform masked difference similarity calculation on the candidate parts to generate a retrieval result sequence.
[0017] Beneficial effects: This invention provides a method and system for retrieving and generating industrial 3D drawings based on difference dimension control. By extracting multi-dimensional difference features from the initial query input and constructing independent subspace representations, and combining these with user-input difference control conditions to generate a unified control representation, it achieves decoupling and dynamic retrieval of CAD model features. This effectively overcomes the limitations of existing technologies, such as rigid static similarity calculations that cannot adapt to the differentiated needs of different engineering positions. By using the unified control representation to conditionally rewrite the query representation, the system can adaptively understand the user's search preferences and transform the user's specific business intent into executable search conditions. Furthermore, a masked difference similarity calculation mechanism is introduced, allowing the system to ignore non-critical dimension difference features and strengthen core constraints during the matching process. This avoids the problem of incorrect filtering of target drawings due to inconsistencies in local details, which is common in traditional methods. This improves the flexibility and matching accuracy of the retrieval process, ensuring that the system can output expected search results when facing different reuse tasks. Attached Figure Description
[0018] Figure 1This is a schematic diagram of the electronic device structure of the hardware operating environment involved in the embodiments of the present invention; Figure 2 A flowchart illustrating the steps of an industrial 3D drawing retrieval and generation method based on differential dimension control, provided in an embodiment of the present invention; Figure 3 This is a schematic diagram of the functional modules of an industrial 3D drawing retrieval and generation method based on difference dimension control, provided in an embodiment of the present invention. Detailed Implementation
[0019] To make the above-mentioned objects, features, and advantages of the present invention more apparent and understandable, the present invention will be further described in detail below with reference to the accompanying drawings and specific embodiments. Obviously, the described embodiments are only some, not all, of the embodiments of the present invention. All other embodiments obtained by those skilled in the art based on the embodiments of the present invention without inventive effort are within the scope of protection of the present invention.
[0020] The present invention will be further described below with reference to the accompanying drawings.
[0021] Reference Figure 1 This is a schematic diagram of the electronic device structure of the hardware operating environment involved in the embodiments of the present invention.
[0022] like Figure 1 As shown, the electronic device may include: a processor 1001, such as a central processing unit (CPU), a communication bus 1002, a user interface 1003, a network interface 1004, and a memory 1005. The communication bus 1002 is used to enable communication between these components. The user interface 1003 may include a display screen or an input unit such as a keyboard; optionally, the user interface 1003 may also include a standard wired interface or a wireless interface. The network interface 1004 may optionally include a standard wired interface or a wireless interface (Wi-Fi). The memory 1005 may be a high-speed random access memory (RAM) or a stable non-volatile memory (NVM), such as a disk drive. Optionally, the memory 1005 may also be a storage device independent of the aforementioned processor 1001.
[0023] Those skilled in the art will understand that Figure 1 The structure shown does not constitute a limitation on the electronic device and may include more or fewer components than shown, or combine certain components, or have different component arrangements.
[0024] like Figure 1 As shown, the memory 1005, which serves as a storage medium, may include an operating system, a data storage module, a network communication module, a user interface module, and computer programs.
[0025] exist Figure 1 In the electronic device shown, the network interface 1004 is mainly used for data communication with the network server; the user interface 1003 is mainly used for data interaction with the user; the processor 1001 and the memory 1005 in the electronic device of the present invention can be set in the electronic device. The electronic device calls the industrial three-dimensional drawing retrieval and generation system based on difference dimension control stored in the memory 1005 through the processor 1001, and executes the industrial three-dimensional drawing retrieval and generation method based on difference dimension control provided in the embodiment of the present invention.
[0026] like Figure 2 As shown, this invention provides a method for retrieving and generating industrial 3D drawings based on differential dimension control. This method is primarily applied to the intelligent management and reuse of CAD data. By transforming traditional single static similarity retrieval into multi-dimensional decoupled, user-intent-controlled dynamic retrieval, this method optimizes the problem in existing technologies that struggle to meet the differentiated reuse needs of different engineering positions.
[0027] Before obtaining the initial query input of industrial 3D drawings, this method is based on constructing and pre-training a retrieval network model with multidimensional difference decoupling encoding capabilities. The step of extracting multidimensional difference features and generating the initial query representation is performed by the pre-trained retrieval network model. This pre-training process specifically includes the following sub-steps S001 to S003: S001. Construct positive and negative sample pairs for industrial 3D drawings.
[0028] The positive sample pairs include part samples that have variations on negligible differences but are identical in core structure, and the negative sample pairs include difficult negative samples that conflict on key constraint differences but are similar in overall outer contour.
[0029] Specifically, the server executes automated data augmentation and historical engineering change record mining scripts to generate a training triplet set. Let the anchor sample be... .
[0030] (1) Positive samples Construction: By calling the CAD geometry kernel application programming interface (API), Apply random parameter perturbations defined as "negligible differences". For example, apply perturbations to all non-critical chamfer dimensions. Randomly modify within the range; or change its surface roughness parameter in the attribute table from Change to These perturbations do not change the main topology and core assembly logic of the parts. By parsing the STEP (Standard for the Exchange of Product model data) file of the International Organization for Standardization (ISO) 10303 standard, the automation script can locate specific cylindrical or planar entities and modify their underlying definition parameters.
[0031] (2) Difficult-to-bear samples Construction: Maintain The rate of change of bounding box volume in Within this range, while maintaining the similarity of the overall macroscopic shape, substantial modifications are made to its local key topology or assembly interfaces. For example, the number of evenly distributed mounting holes on the flange is changed from 4 to 5, or the tolerance grade of the center locating hole is changed from H7 to a non-fitting free tolerance. Such samples have high training value for the model and can guide the model to learn deep geometric semantic constraints.
[0032] S002. Input positive and negative sample pairs into the retrieval network model to be trained, and apply different preset control conditions during the training process to supervise different similarity targets.
[0033] The retrieval network model to be trained is a multi-branch heterogeneous neural network architecture used to process industrial drawing data of different modalities and structures. The specific hierarchy, connection relationships, and hyperparameter settings of the model are as follows: (1) Topology processing branch: Used to process B-Rep of 3D drawings. First, convert the B-Rep into an attribute graph. Among them, the node set Represents the faces and edge sets in the drawing. This represents the adjacent edges between faces.
[0034] Node feature vectors The dimension is set to 64, including the type of surface (using one-hot encoding to represent planes, cylindrical surfaces, non-uniform rational B-spline surfaces, etc.), area ratio, perimeter ratio, etc.
[0035] Edge feature vector The dimension is set to 32, including edge type (straight line, arc), concavity / convexity (obtained by calculating the dot product and angle between the normal vectors of adjacent faces), dihedral angle, etc.
[0036] A three-layer Graph Attention Network (GAT) is used for feature aggregation. The formula for updating the node features of a layer is:
[0037] In the formula, Represents a node In the The feature vector of the layer; Represents a node The set of neighboring nodes; Indicates the first The learnable weight matrix of the layer has dimensions of ,in Setting it to 128, for medium-complexity industrial parts containing tens to hundreds of faces, a 128-dimensional hidden layer can retain sufficient topological information while avoiding the risk of overfitting caused by excessive dimensionality. This represents a non-linear activation function. In this embodiment, the LeakyReLU function is used, with its negative half-axis slope set to 0.2. A negative half-axis slope of 0.2 can maintain gradient stability during gradient backpropagation in graph neural networks and prevent node features from tending to zero after multi-layer aggregation. Represents a node and nodes The attention weights between them are calculated using the following formula:
[0038] In the formula, Representing neighboring nodes In the The feature vector of the layer; Represents a node and nodes Similarly, the eigenvectors of the edges between them Represents a node and nodes The feature vector of the edge between them; This represents the learnable parameter vector for the attention mechanism. This represents a vector concatenation operation. The GAT branch ultimately outputs a 256-dimensional topological representation vector through global average pooling.
[0039] (2) Local Feature Branch: A three-dimensional convolutional neural network (3D-CNN) is used. First, the local regions of interest (such as holes and grooves) of the CAD model are voxelized using a ray casting algorithm. The 3D-CNN consists of four consecutive 3D convolutional blocks. Each convolutional block contains a 3D convolutional layer, a batch normalization layer, a linear rectified function layer, and a max pooling layer. The kernel size of the first two convolutional blocks is set to [size missing]. The stride is 1; the kernel size of the last two convolutional blocks is set to... The step size is 1. The final feature map is flattened and output as a 256-dimensional spatial distribution feature vector through a fully connected layer.
[0040] (3) Attribute processing branch: Processing numerical and textual parameters. For numerical parameters (such as length and diameter), maximum and minimum value normalization is used to map them to the [0, 1] interval; for textual attributes (such as material grade), a pre-trained word embedding model is used to convert them into dense vectors. Then, these two parts are concatenated and input into a two-layer multilayer perceptron. The first layer contains 256 neurons and the second layer contains 128 neurons, outputting a 128-dimensional attribute representation vector.
[0041] During training, the server randomly generates preset control conditions. (Represented as a Boolean mask vector corresponding to the number of dimensions). For example, if If the model is set to ignore tolerances and material dimensions, then during the forward propagation calculation, the corresponding dimension vector components output by the attribute processing branch will be forcibly set to zero. The model is trained to: in the current Under the given conditions, the distance between the calculated anchor point sample and the positive sample is minimized, while the distance with the negative sample is maximized.
[0042] S003. The retrieval network model is trained based on contrastive learning, enabling the retrieval network model to have the decoupled coding ability to separate negligible differences and extract key constraint conflict features.
[0043] Gradient optimization is performed using a supervised contrastive loss function with conditional masking. The loss function formula is as follows:
[0044] In the formula, This represents the conditional loss value based on contrastive learning; The feature representation vector of the anchor point part is formed by concatenating the output vectors of each branch. Indicates the first part corresponding to the anchor point. A feature representation vector of positive samples; Indicates the first part corresponding to the anchor point. A feature representation vector for a difficult negative sample; Indicates the number of positive samples in a batch; This represents the total number of negative samples in a batch; This indicates the currently applied preset control conditions; Indicates under control conditions The cosine similarity is calculated using only the following parameters. Calculate the dot product of subvectors with a mask of 1 in the middle dimension; This indicates the temperature hyperparameter. In this embodiment, The value range is limited to [0.05, 0.20], with a preferred value of 0.07.
[0045] Temperature overparameters Its function is to adjust the model's sensitivity to hard-negative samples. If The exponential amplification effect of similarity distribution is too severe, and the model is prone to overfitting to a few extremely similar negative samples within a batch, leading to gradient instability; if As the distribution smooths out, the model's ability to distinguish difficult negative samples with only subtle local topological differences decreases. Experiments show that 0.07 can maintain gradient stability and clear classification boundaries in the multidimensional feature decoupling space.
[0046] The AdamW optimizer is used for parameter updates. The initial learning rate is set to... A cosine annealing learning rate decay strategy is adopted, with the weight decay coefficient set at... Within a certain range, to prevent overfitting of large-parameter models on a limited industrial drawing dataset. The pre-training process ends after iterations until the loss function converges on the validation set.
[0047] After pre-training is complete, the server executes the main interactive multidimensional difference retrieval process. Combined with... Figure 2 The process specifically includes steps S101 to S106: S101. Obtain the initial query input of the industrial 3D drawing, extract multidimensional difference features from the initial query input, parse the multidimensional difference features to generate the initial query representation, the initial query representation includes multiple difference dimension subspace representations formed by the independent encoding of each multidimensional difference feature.
[0048] This step is fundamental to achieving feature decoupling and includes the following detailed execution logic: S1011. Initial query input for obtaining industrial 3D drawings.
[0049] The server receives query objects uploaded by users through their terminals. This initial query input includes: standard product data exchange format files (such as STEP AP203 / AP242 format), natural language text containing engineering intent, or unique part identification codes already existing in the product lifecycle management system. When the input is a code, the server automatically retrieves the corresponding 3D model data from the database.
[0050] S1012. Extract the main geometric contour features, boundary representation topology features, local manufacturing features, assembly interface features, parameter size features, tolerance and datum features, material and process attribute features, and historical business attribute features from the initial query input as various multidimensional difference features.
[0051] The server relies on a pre-trained retrieval network model to perform multi-threaded feature extraction: (1) Extraction of main geometric contour features: Calculate the principal inertial axis matrix of the query part, and perform spatial attitude normalization and alignment of the model through principal component analysis (PCA). Then, generate multi-view depth maps based on orthogonal projection to extract global features that reflect the macroscopic volume distribution of the part.
[0052] (2) Boundary representation topology feature extraction: Parse the face, edge and vertex entity topology tree in the STEP file, construct the attribute graph, and capture the internal geometric connection semantics.
[0053] (3) Local manufacturing feature extraction: Combining rule-based geometric feature recognition algorithm with 3D-CNN, identify and locate machining features such as threaded holes, countersunk holes, blind holes, chamfers, and undercut grooves.
[0054] (4) Assembly interface feature extraction: Traverse the normal vector distribution of the model surface, filter out surfaces with high flatness and large area ratio, and identify potential flange surfaces, locating pin holes and other interface areas used for interaction between parts.
[0055] (5) Extraction of parameter size features: Extract key numerical dimensions of the analytical surface, such as the radius of the cylindrical surface, directly from the underlying parameter definition of the B-Rep entity.
[0056] (6) Tolerance and datum feature extraction: Based on the semantic labels defined in the model, extract the form and position tolerances such as flatness and coaxiality, as well as the datum surface system.
[0057] (7) Material process attribute feature extraction: Extract text attributes such as material grade and heat treatment requirements from the metadata table associated with the model.
[0058] (8) Extraction of historical business attribute features: Extract the material category family, reuse frequency and supplier information of the drawing in the company's historical projects.
[0059] S1013. Encode each multidimensional difference feature independently to generate the corresponding feature sub-vector.
[0060] The eight categories of features extracted above are fed into the corresponding encoder branches with fixed parameters in the retrieval network model. Since the model has been subjected to decoupling constraints during pre-training, each output feature sub-vector independently expresses a single-dimensional engineering semantic. For example, fixed-length main contour sub-vectors and fixed-length material feature sub-vectors are generated.
[0061] S1014. Combine the feature sub-vectors to form a multi-dimensional subspace representation with different characteristics.
[0062] Suppose a total of Features in 1 dimension (in this embodiment) ). This The subvectors are concatenated to form the initial query representation matrix. The initial query representation is structured into a matrix consisting of an ordered combination of representations from multiple subspaces, facilitating subsequent dimensional orientation operations.
[0063] S102. Receive user-differentiated control conditions for industrial 3D drawings, and standardize the user-differentiated control conditions into a unified control representation. The unified control representation is used to quantify the control logic of the differential dimension subspace representation.
[0064] This step transforms subjective business requirements into explicit mathematical variables. Specifically, it includes: S1021, Receive user-defined control conditions for industrial 3D drawings.
[0065] Users input their control intentions through the terminal interface. Input methods include: natural language descriptions (such as "ignore the chamfer, but the four mounting holes at the bottom must be in the same position, and the total length is about 200mm"), sliders and checkboxes in the graphical interface, or preset task templates built into the system.
[0066] S1022. The triggered user-differentiated control conditions are parsed and converted into a unified control representation consisting of multiple control parameters.
[0067] When receiving natural language, the server invokes a named entity recognition model based on the Transformer architecture to perform slot filling. For example, "ignore chamfer" is mapped to setting the mask corresponding to the chamfer feature to zero; "consistent mounting hole positions" is mapped to a hard constraint of the hole system feature. For graphical input, it is directly converted into parameters through a preset dictionary mapping table.
[0068] S1023, Unified Control Representation Defined as a quadruple: .
[0069] Dimension weight set : Used to characterize the degree of influence of each difference dimension subspace representation. The value range is... And requires 0.0 indicates that this dimension has no impact, while 1.0 indicates that this dimension plays a dominant role. Normalization is performed to maintain the comparability of the final scores across different retrieval tasks.
[0070] Dimensional mask set : Used to determine whether the representations of each difference dimension subspace participate in the calculation. The value range is... Setting basis: Used for logical pruning of the execution dimension, when... At this time, the dimension is inactive, cutting off its distance propagation in subsequent calculations.
[0071] Hard constraint set : A set of Boolean expressions used for rigorous filtering of candidate parts. Rationale: In industrial assembly, minute differences in interface dimensions can prevent assembly; therefore, hard filtering, rather than floating-point vector similarity calculation, must be used.
[0072] Variable range threshold set Used to define the tolerance range for parameter fluctuations. For example, defining the aperture parameter. Tolerance range Following the tolerance and fit principles in industrial design, it allows for the search for alternative parts within the standard tolerance zone.
[0073] S103. Based on the unified control representation, perform conditional rewriting on the differential dimension subspace representation to update the initial query representation and generate a conditional query representation.
[0074] The server directly transforms the query vector in the feature space. Specifically, this includes: S1031. Based on the dimension mask in the unified control representation, for the dimension mask in the inactive state, the corresponding differential dimension subspace representation is masked during the rewriting process.
[0075] For each dimension If the parsed mask Then the initial query representation matrix will be... The corresponding number in Subspace vectors Perform a zeroing operation: This ensures that the ignored dimension does not interfere with the similarity calculation.
[0076] S1032. Based on the dimension weights in the unified control representation, perform gain amplification or weight reduction processing on the corresponding differential dimension subspace representation using the dimension weights.
[0077] For dimensions that are not masked ( ), using weights Perform a combined layer-normalized gain projection on the feature vectors:
[0078] In the formula, Indicates the rewritten first... A subspace representation of distinct dimensions; The first in the unified control representation Dimensional mask for each difference dimension; Represents the first in the initial query representation A subspace representation of distinct dimensions; The first in the unified control representation Dimension weights for each difference dimension; For layer normalization operation, This is the gain amplification factor. The value range is set between [0.5, 2.0], and in this embodiment, it is preferably 1.2.
[0079] like The gain amplification effect is not obvious; if This will cause distortion in the rewritten vector, deviating from the manifold structure established by the pre-trained model, thus recalling irrelevant noise samples. A value of 1.2 can effectively lengthen the vector magnitude of the dimension of interest while maintaining the feature space structure.
[0080] S1033. Based on the set of hard constraints in the unified control representation, for the constraints that exist in the set of hard constraints, add hard constraint labels to the corresponding differential dimension subspace representations.
[0081] Convert hard constraint rules into unique integer tag identifiers. For example, map "contains a specific thread" to a specific tag code and attach it as metadata to a vector data structure, specifically for triggering subsequent deterministic queries.
[0082] S1034. The representations of each differential dimension subspace after masking, gain amplification or weight reduction and additional hard constraint labeling are merged to generate a conditional query representation.
[0083] The transformed subspace vectors are recombine with the hard constraint labels to generate a complete conditional query representation. .
[0084] S104. Based on unified control representation and conditional query representation, perform candidate recall in the preset industrial 3D drawing database to obtain candidate parts, and perform masked difference similarity calculation on the candidate parts to generate a search result sequence.
[0085] This step employs a cascading retrieval architecture, specifically including: S1041. Using the hard constraint set in the unified control representation, filter multiple 3D parts stored in the industrial 3D drawing database, and retain the parts that meet the hard constraint set conditions to form an initial candidate part set.
[0086] If the conditional query representation has hard constraint markers, the server first performs exact matching in the pre-built inverted index or attribute graph database to eliminate parts that do not meet the strong constraints, thus reducing the search space for subsequent vector operations.
[0087] S1042. Use conditional query representation to perform conditional vector recall on the parts in the initial candidate parts set, obtain a coarse-ranked candidate parts list, and use the parts in the coarse-ranked candidate parts list as candidate parts.
[0088] A hierarchical navigation small-world algorithm is used to construct a high-dimensional vector index. This is represented by conditional queries. The floating-point vector part is the center point, and the search is performed in the initial candidate part set to find the closest inner product distance. Nodes (e.g.) ), as candidate parts.
[0089] S1043. Perform masked difference similarity calculation on each candidate part to obtain the comprehensive similarity score between the initial query input and each candidate part.
[0090] Retrieve the complete multidimensional feature representation corresponding to the candidate parts. The specific calculation steps are as follows: Calculate the local similarity between the subspace representations of each difference dimension in the conditional query representation and the corresponding features of the candidate parts:
[0091] In the formula, Indicates the first Local similarity in each dimension; In the representation of conditional query, the first A subspace representation of distinct dimensions; Indicates the first candidate part 1 eigenvector; This represents calculating the L2 norm (i.e., the vector magnitude) of a vector. The weighted similarity contribution value for each local similarity is obtained by multiplying each local similarity with the corresponding dimensional weight and dimensional mask in the unified control representation. .
[0092] The test checks whether the parameter characteristics of candidate parts exceed the variable range threshold set in the unified control representation. If the parameters... Deviated from the tolerance range Calculate the penalty items for violations :
[0093] In the formula, Indicates the first Violation penalty items for each parameter feature; Indicates the candidate part in the first The actual value of each parameter feature; and These represent the upper and lower threshold values of the variable range set for this parameter in the unified control representation, respectively. This represents the function that takes the maximum value.
[0094] Combined with the preset penalty intensity coefficient Get the total penalty value. The value range is set to [0.1, 10.0]. Cosine similarity is normalized between [-1, 1]. To ensure that the penalty term and the similarity score are comparable, when the size deviation is in millimeters, Set to a smaller value (e.g., 0.1); when deviating from precision tolerances in the micrometer range, Scale up to a larger value (e.g., 10.0).
[0095] The weighted similarity contributions of all difference dimension subspaces are summed, and the total penalty value is subtracted to obtain the comprehensive similarity score:
[0096] In the formula, Indicated in unified control representation Under the condition of initial query input With candidate parts A comprehensive similarity score between them; This represents the total number of extracted difference dimensions; This represents the total number of parameter features that are subject to checks based on a variable range threshold set. and They represent the first Dimension weights and dimensional masks for each dimension; Indicates the first The penalty intensity coefficient for each parameter.
[0097] S1044. Sort each candidate part in descending order according to the comprehensive similarity score, generate the final search result sequence, and output it to the terminal.
[0098] After generating the search result sequence, the method also includes a multi-round interactive feedback and preference convergence step S105: S1051. Receive interactive feedback information submitted by the user regarding the search result sequence.
[0099] Interactive feedback information includes retention operations for specific candidate parts, deletion operations, or reason annotation information for specific multidimensional difference features (such as annotation "deleted due to assembly interface inconsistency").
[0100] S1052. Based on interactive feedback information, dynamically adjust the unified control representation.
[0101] The server updates the weight vector in the control representation using the gradient descent algorithm. Let the first... The weight of the wheel is Based on feedback loss Update:
[0102] In the formula, Indicates the first The updated dimension weight vector; Indicates the first The current dimension weight vector; This represents the normalization exponential function, used to ensure that the sum of the updated weights is 1; Indicates feedback loss For weight vector The gradient vector; This indicates the feedback update step size, with a value range limited to [0.01, 0.20]. Setting basis: If... Drastic fluctuations in weights can cause a jump in the next round of search results, reducing system controllability; if The feedback response is sluggish, increasing the number of convergence rounds. A moderate step size can smoothly guide the convergence of results within a finite number of rounds.
[0103] S1053. Based on the adjusted unified control representation, regenerate the conditional query representation, and perform a new round of candidate recall and masked difference similarity calculation based on the updated conditional query representation, until the new round of retrieval result sequence satisfies the user's convergence preference.
[0104] S1054. Save the unified control representation at the convergence preference as a historical preference template. Extract the current combination of control parameters and persist it for direct retrieval in subsequent searches with the same task intent, thereby improving retrieval efficiency.
[0105] The step of generating the search result sequence also includes a dimensional explanation output step S106: S1061. When outputting the search result sequence containing each candidate part, synchronously generate and display the dimensional explanation information corresponding to each candidate part.
[0106] S1062. Dimensional explanation information is generated by the background rule generation engine based on the comparison results of the initial query representation, the characteristics of each candidate part, and the unified control representation.
[0107] S1063. Dimensional explanation information includes: descriptions of matching dimensions that demonstrate high similarity between candidate parts and the initial query input (dimensions with high local similarity and high weight); and descriptions of ignored dimensions that have been masked according to the dimension mask (corresponding to...). The system includes descriptions of conflict dimensions (such as those involving the violation of hard constraints or penalties leading to reduced similarity), and suggested 3D geometric modifications based on multidimensional differences in conflict features using an expert system rule base. This provides engineers with ample decision-making support and enhances the engineering interpretability of the results.
[0108] This invention also provides an industrial 3D drawing retrieval and generation system 200 based on difference dimension control, referring to... Figure 3 This paper illustrates the functional module structure of an industrial 3D drawing retrieval and generation method 200 based on difference dimension control according to an embodiment of the present invention. The system may include multiple logical functional modules that cooperate with each other to implement the industrial 3D drawing retrieval and generation method based on difference dimension control according to any of the foregoing embodiments. The multiple logical functional modules include: The query input parsing module 201 is used to obtain the initial query input of the industrial 3D drawing, extract multidimensional difference features from the initial query input, parse the multidimensional difference features to generate the initial query representation, and the initial query representation includes multiple difference dimension subspace representations formed by the independent encoding of each multidimensional difference feature. User control standardization module 202 is used to receive user-differentiated control conditions for industrial 3D drawings, standardize the user-differentiated control conditions into a unified control representation, and use the unified control representation to quantify the control logic represented by the differential dimension subspace. The query rewrite generation module 203 is used to perform conditional rewriting on the differential dimension subspace representation according to the unified control representation to update the initial query representation and generate a conditional query representation. The retrieval, sorting, and output module 204 is used to perform candidate recall in a preset industrial 3D drawing database based on unified control representation and conditional query representation to obtain candidate parts, and to perform masked difference similarity calculation on the candidate parts to generate a retrieval result sequence.
[0109] The specific embodiments described above further illustrate the purpose, technical solution, and beneficial effects of the present invention. It should be understood that the above description is only a specific embodiment of the present invention and is not intended to limit the scope of protection of the present invention. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of the present invention should be included within the scope of protection of the present invention.
Claims
1. A method for retrieving and generating industrial 3D drawings based on differential dimension control, characterized in that, Includes the following steps: The initial query input of the industrial 3D drawing is obtained, multi-dimensional difference features are extracted from the initial query input, and the multi-dimensional difference features are parsed to generate an initial query representation. The initial query representation includes multiple difference dimension subspace representations formed by independently encoding each of the multi-dimensional difference features. Receive user-differentiated control conditions for the industrial 3D drawing, and normalize the user-differentiated control conditions into a unified control representation, wherein the unified control representation is used to quantify the control logic represented by the differential dimension subspace. Based on the unified control representation, the conditional rewriting of the differential dimension subspace representation is performed to update the initial query representation, generating a conditional query representation; Based on the unified control representation and the conditional query representation, candidate recall is performed in the preset industrial 3D drawing database to obtain candidate parts, and masked difference similarity calculation is performed on the candidate parts to generate a search result sequence.
2. The industrial 3D drawing retrieval and generation method based on difference dimension control as described in claim 1, characterized in that, The step of extracting multidimensional difference features from the initial query input and parsing the multidimensional difference features to generate an initial query representation specifically includes: Extract the main geometric contour features, boundary representation topology features, local manufacturing features, assembly interface features, parameter size features, tolerance and datum features, material and process property features, and historical business property features from the initial query input as the multidimensional difference features for each item; Each of the multidimensional difference features is independently encoded to generate a corresponding feature sub-vector; The feature vectors described in each item are combined to form the multiple differential dimension subspace representations.
3. The industrial 3D drawing retrieval and generation method based on difference dimension control as described in claim 1, characterized in that, The step of standardizing the user-differential control conditions into a unified control representation specifically includes: The triggered user-differential control conditions are parsed and converted into a unified control representation consisting of multiple control parameters; The unified control representation includes: dimension weights for characterizing the degree of influence of each of the differential dimension subspace representations, dimension masks for determining whether each of the differential dimension subspace representations participates in the calculation, a set of hard constraints for strictly filtering the candidate parts, and a set of variable range thresholds for defining the tolerance range of parameter fluctuations.
4. The industrial 3D drawing retrieval and generation method based on difference dimension control as described in claim 3, characterized in that, The step of performing conditional rewriting on the differential dimension subspace representation based on the unified control representation to update the initial query representation and generate a conditional query representation specifically includes: Based on the dimension mask in the unified control representation, for the dimension mask that is in an inactive state, its corresponding differential dimension subspace representation is masked during the rewriting process; Based on the dimension weights in the unified control representation, the corresponding differential dimension subspace representation is subjected to gain amplification or weight reduction processing using the dimension weights; Based on the set of hard constraints in the unified control representation, for the constraints existing in the set of hard constraints, a hard constraint label is added to the corresponding differential dimension subspace representation; The conditional query representation is generated by fusing the various differential dimension subspace representations after masking, gain amplification or weight reduction, and additional hard constraint labeling.
5. The industrial 3D drawing retrieval and generation method based on difference dimension control as described in claim 4, characterized in that, The steps of performing candidate recall in a preset industrial 3D drawing database to obtain candidate parts based on the unified control representation and the conditional query representation, and performing masked difference similarity calculation on the candidate parts to generate a search result sequence, specifically include: Using the set of hard constraints in the unified control representation, multiple 3D parts stored in the industrial 3D drawing database are filtered, and parts that meet the conditions of the set of hard constraints are retained to form an initial candidate part set. The conditional query representation is used to perform conditional vector recall on the parts in the initial candidate part set to obtain a coarse-ranked candidate part list, and the parts in the coarse-ranked candidate part list are used as the candidate parts; Perform the masked difference similarity calculation on each of the candidate parts to obtain a comprehensive similarity score between the initial query input and each of the candidate parts; The candidate parts are sorted according to the comprehensive similarity score to generate the final search result sequence.
6. The industrial 3D drawing retrieval and generation method based on difference dimension control as described in claim 5, characterized in that, The step of performing the masked difference similarity calculation on each of the candidate parts to obtain the comprehensive similarity score between the initial query input and each of the candidate parts specifically includes: Calculate the local similarity between each of the difference dimension subspace representations in the conditional query representation and the corresponding features of the candidate parts; Each local similarity is multiplied together with the corresponding dimension weight and dimension mask in the unified control representation to obtain the weighted similarity contribution value of each difference dimension subspace representation. The parameter characteristics of the candidate part are detected to see if they exceed the variable range threshold set in the unified control representation or violate the hard constraint set. The violation penalty item is calculated based on the exceeded feature range or violated constraint condition, and the total penalty value is obtained by combining the preset penalty intensity coefficient. The weighted similarity contribution values of all the difference dimension subspaces are summed, and the total penalty value is subtracted from the summation result to obtain the comprehensive similarity score.
7. The industrial 3D drawing retrieval and generation method based on difference dimension control as described in claim 1, characterized in that, After generating the search result sequence, the method further includes a multi-round interactive feedback and preference convergence step: Receive interactive feedback information submitted by the user for the search result sequence, the interactive feedback information including retention operation, deletion operation or reason annotation information for specific candidate parts or specific multidimensional difference features; The unified control representation is dynamically adjusted based on the interactive feedback information. Based on the adjusted unified control representation, the conditional query representation is regenerated, and a new round of candidate recall and masked difference similarity calculation is performed based on the updated conditional query representation until the new round of the retrieval result sequence satisfies the user's convergence preference. The unified control representation at the convergence preference is saved as a historical preference template for use in subsequent retrieval tasks.
8. The industrial 3D drawing retrieval and generation method based on difference dimension control as described in claim 3, characterized in that, The step of generating the search result sequence also includes a dimensional explanation output step: When outputting each of the candidate parts contained in the search result sequence, dimensional explanation information corresponding to each candidate part is generated and displayed synchronously. The dimensional explanation information is generated based on the comparison results of the initial query representation, the features of each candidate part, and the unified control representation; The dimensional explanation information includes: a description of the matching dimensions that indicate a high similarity match between the candidate part and the initial query input; a description of the ignored dimensions that have been masked according to the dimensional mask; a description of the conflicting dimensions that violate the set of hard constraints and cause a decrease in similarity; and a three-dimensional geometric modification suggestion item for the conflicting multidimensional difference features.
9. The industrial 3D drawing retrieval and generation method based on difference dimension control as described in claim 1, characterized in that, The step of extracting multidimensional differential features and generating an initial query representation is performed by a pre-trained retrieval network model; prior to obtaining the initial query input of the industrial 3D drawing, the method further includes a pre-training step of the retrieval network model: Construct positive and negative sample pairs for industrial 3D drawings. The positive sample pairs include part samples that have variations on negligible differences but are the same on the core structure. The negative sample pairs include difficult negative samples that conflict on key constraint differences but are similar on the overall outer contour. The positive sample pairs and the negative sample pairs are input into the retrieval network model to be trained, and different preset control conditions are applied during the training process to supervise different similarity targets; The retrieval network model is trained based on contrastive learning, enabling it to decouple the encoding capabilities of separating ignorable differences and extracting key constraint conflict features.
10. An industrial 3D drawing retrieval and generation system based on differential dimension control, characterized in that, It comprises multiple functional modules for performing the industrial 3D drawing retrieval and generation method based on difference dimension control as described in any one of claims 1 to 9, and includes the following interconnected modules: The query input parsing module is used to obtain the initial query input of the industrial 3D drawing, extract multidimensional difference features from the initial query input, parse the multidimensional difference features to generate an initial query representation, and the initial query representation includes multiple difference dimension subspace representations formed by independently encoding each of the multidimensional difference features. The user control standardization module is used to receive user-differentiated control conditions for the industrial 3D drawings, and standardize the user-differentiated control conditions into a unified control representation. The unified control representation is used to quantify the control logic represented by the differential dimension subspace. The query rewrite generation module is used to perform conditional rewriting on the differential dimension subspace representation according to the unified control representation to update the initial query representation and generate a conditional query representation. The retrieval, sorting, and output module is used to perform candidate recall in a preset industrial 3D drawing database to obtain candidate parts based on the unified control representation and the conditional query representation, and to perform masked difference similarity calculation on the candidate parts to generate a retrieval result sequence.
