File digital management system and method
Through three-dimensional modeling, digital twin technology and genetic algorithm optimization, the problem of low file storage efficiency is solved, and efficient utilization and intelligent management of file storage areas are realized.
Patent Information
- Application Number
- CN202411757052.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-12-03
- Publication Date
- 2025-03-25
AI Technical Summary
Archive storage efficiency is low, and traditional storage methods have problems such as low space utilization, difficulty in retrieval, and data islands, making it difficult to adapt to the dynamic growth of archives and diversified storage needs.
The digital model of the archive storage area is constructed through three-dimensional modeling and digital twin technology, and the archive metadata is extracted using OCR and natural language processing technology, and the archive storage path and location are optimized in combination with genetic algorithms.
It improves the efficiency of archive storage, realizes efficient use of space and intelligent archive management, and enhances the efficiency and convenience of archive retrieval.
Smart Images

Figure CN119692937A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of digital archive management, and in particular to a digital archive management system and method. Background Art
[0002] With the development of the information age, the number of archives generated by various industries and departments is growing, and archive management is facing unprecedented opportunities and challenges. The traditional paper archive storage method has problems such as low space utilization, difficult retrieval, and data islands, which seriously restricts the improvement of archive management efficiency and the value of archives. In order to adapt to the development needs of the information society and realize the modernization, refinement and intelligence of archive management, it is urgent to innovate archive management concepts and technical means.
[0003] At present, various fields are actively exploring effective ways to manage digital archives. Some units have introduced information management systems to digitally identify and manage archive carriers through barcodes, RFID and other technical means, but lack in-depth mining and related use of archive content. Some institutions have tried to use emerging technologies such as big data and artificial intelligence to process archives intelligently, but lack the integration of physical and digital spaces of archives. Research on digital reconstruction of archive storage environments using technologies such as three-dimensional modeling and digital twins is still relatively lacking. Overall, the practice of digital archive management is still in the initial exploration stage, and theories and technologies need further innovation and breakthroughs.
[0004] In the field of archive storage management, the problems of low space utilization efficiency of archive warehouses and low efficiency of archive storage and access are particularly prominent. Traditional archive storage mostly uses fixed shelves. The specifications and layout of storage units lack flexibility, making it difficult to adapt to the dynamic growth of archives and the needs of diversified storage, resulting in serious waste of space. Archive shelving mostly relies on manual work, and there is a lack of optimization of archive storage paths. Archives often pile up and access paths overlap, resulting in low efficiency in storage and retrieval. Summary of the invention
[0005] In response to the problem of low archive storage efficiency in the prior art, the present application provides an archive digital management system and method, which constructs a digital model of the archive storage area through three-dimensional modeling and digital twin technology, extracts archive metadata using OCR and natural language processing technology, and combines genetic algorithms to optimize archive storage paths and locations, thereby improving storage efficiency.
[0006] The purpose of this application is achieved through the following technical solutions.
[0007] One aspect of the present application provides a digital archive management method, including: obtaining three-dimensional point cloud data of an archive storage area, processing the three-dimensional point cloud data using three-dimensional modeling software, generating a three-dimensional digital model of the archive storage area, and extracting the spatial coordinates of the archive storage area; importing the three-dimensional digital model of the archive storage area into BIM software, associating and mapping the physical space information of the archive storage area with the three-dimensional digital model, and constructing a digital twin model of the archive storage area; collecting the cover and directory images of the archive, using an OCR model based on a convolutional neural network, recognizing the image through an ORC model, extracting the text content in the image, and generating metadata of the archive; associating the metadata of the archive with the digital twin model of the archive storage area, using a genetic algorithm, taking the spatial coordinates of the archive storage area as constraints, and taking access efficiency and space utilization as optimization goals, calculating the optimal path of the archive from storage to a target storage location, and generating an optimal storage plan for the archive; according to the optimal storage plan for the archive, storing the archive in the target storage location, and associating the structured metadata, storage location, and timestamp of the archive into a database.
[0008] Furthermore, a three-dimensional digital model of the archive storage area is generated, and the spatial coordinates of the archive storage area are extracted, including: using a three-dimensional laser scanner to scan the archive storage area to obtain the three-dimensional point cloud data of the archive storage area; importing the three-dimensional point cloud data into the three-dimensional modeling software, using the voxel filtering method to downsample and denoise the three-dimensional point cloud data, and removing outliers and duplicate points in the three-dimensional point cloud data; specifically, the space where the three-dimensional point cloud data is located is divided into cube grids of equal size, and each cube is called a voxel. The size of the voxel determines the resolution of the downsampling. The larger the voxel, the fewer the sampling points and the lower the point cloud accuracy; the smaller the voxel, the more the sampling points and the higher the point cloud accuracy. The selection of the voxel size requires weighing factors such as the density of the point cloud, the noise level, and the computational efficiency.
[0009] Assume that the spatial range of the point cloud data is [x min ,x max ]×[y min ,y max ]×[z min ,z max ], the side length of the voxel is d, then the number of voxels is: in, is the rounding function. Point cloud allocation, each point cloud data point P i (x i ,y i ,z i ) is assigned to the corresponding voxel V j Middle. Click P i The voxel index (j x ,jy ,j z ) can be calculated by the following formula:
[0010] in, is the floor rounding function. i Add to Voxel V j The point set is denoted as V j = {P i |P i in V j If multiple points fall into the same voxel, they are considered duplicate points or neighboring points.
[0011] Outlier removal, for each non-empty voxel V j , calculate the center point C of its point set j (x c ,y c ,z c ): Where, represents the voxel V j The number of midpoints. Calculate each point P i To center point C j The distance d i : Set a distance threshold t, if d i >t, then point P i Marked as an outlier, from voxel V j The distance threshold t needs to be adjusted according to the density and noise level of the point cloud, and can usually be set to 1 to 3 times the voxel side length d. Duplicate point removal, for each non-empty voxel V j , randomly select a point P k As the representative point, remove other points from the point set. You can also select the center point C j Or the point closest to the center point is used as the representative point. Downsampling point cloud generation, each non-empty voxel V j The representative point P k Compose a new point cloud dataset Q: Point cloud Q is the downsampled point cloud. Compared with the original point cloud, the number of points is greatly reduced, and noise and duplicate points are also removed. Parameter adjustment, the performance of the voxel filtering algorithm depends on the selection of voxel size d and distance threshold t. The larger d is, the sparser the downsampled point cloud is, the better the denoising effect is, but some detail information may be lost; the smaller d is, the denser the downsampled point cloud is, more details are retained, but the denoising effect is poor. The larger t is, the more points are marked as outliers, the stronger the ability to remove noise is, but some normal points may be mistakenly deleted; the smaller t is, the fewer points are marked as outliers, more original information is retained, but the noise removal is not thorough.
[0012] The 4PCS registration algorithm is used to perform spatial registration on the filtered 3D point cloud data, and the coordinates of the 3D point cloud data obtained by scanning at different angles are unified and merged into a complete 3D point cloud model; the registered 3D point cloud model is triangulated, and the Delaunay triangulation algorithm is used to generate the mesh surface of the 3D point cloud model according to the point spacing and curvature of the 3D point cloud model, thereby generating a 3D digital model of the archive storage area.
[0013] The RANSAC algorithm is used to calibrate the coordinates of the three-dimensional digital model and extract the spatial coordinates of the archive storage in the three-dimensional digital model, including: randomly selecting a set of point sets as sample point sets in the three-dimensional digital model, fitting the characteristic plane or characteristic edge where the sample point set is located, and establishing a local coordinate system of characteristic elements; extracting the characteristic plane and characteristic edge of the archive storage facility in the three-dimensional digital model as reference characteristic elements; calculating the distance error between the reference characteristic element and the characteristic element obtained by fitting the sample point set, and judging whether the sample point set is an in-place point set according to the distance error; repeatedly performing the operation to count the number of in-place point sets, when the number of in-place point sets reaches a preset threshold, taking the characteristic element obtained by the current fitting as the optimal characteristic element, and taking the in-place point set as the optimal in-place point set; using the optimal in-place point set, estimating the coordinate transformation relationship between the optimal characteristic element and the actual spatial coordinate system, and establishing the global spatial coordinate system of the three-dimensional digital model; calibrating the spatial coordinate range of the archive storage area in the three-dimensional digital model according to the positional relationship between the global spatial coordinate system and the optimal characteristic element; extracting the spatial coordinate information of the archive storage position in the three-dimensional digital model within the calibrated spatial coordinate range, including the position coordinates, size and other parameters of the archive storage unit.
[0014] Furthermore, the three-dimensional point cloud model is merged, including: randomly selecting a group of point cloud data as the reference point cloud from the filtered three-dimensional point cloud data, and the remaining point cloud data as the point cloud to be registered; randomly selecting 4 non-coplanar points in the reference point cloud to form a basis set, and calculating the consistency descriptor of the basis set, and the consistency descriptor contains the distance between the 4 points; in each point cloud to be registered, the kd tree algorithm is used to perform the nearest neighbor search to obtain the candidate matching basis set with the smallest distance to the consistency descriptor of the basis set; the rigid body transformation matrix between each candidate matching basis set and the basis set is calculated, and the coordinates of all points in the point cloud to be registered are transformed according to the rigid body transformation matrix to obtain the registered three-dimensional point cloud.
[0015] The registered 3D point cloud and the reference point cloud are unified in coordinates to form a complete 3D point cloud model, including: calculating the registration error between the registered 3D point cloud and the reference point cloud, selecting the optimal registration result with a registration error less than the error threshold by setting an error threshold, obtaining the rigid body transformation matrix corresponding to the optimal registration result as the optimal rigid body transformation matrix; using the optimal rigid body transformation matrix, converting the coordinate system of the registered 3D point cloud to the coordinate system of the reference point cloud to achieve coordinate system one; performing weighted fusion on the 3D point cloud after coordinate system one, setting the weight coefficient according to the registration error of the point cloud, and calculating the coordinates of the fused 3D point cloud; updating the reference point cloud according to the coordinates of the fused 3D point cloud to obtain the registered 3D point cloud model.
[0016] Furthermore, constructing a digital twin model of the archive storage area includes: importing the three-dimensional digital model of the archive storage area into BIM software to construct a BIM model of the archive storage area; extracting the physical space information of the archive storage facility in the BIM model, the physical space information including the spatial layout, equipment location and pipeline direction of the archive storage area; for the spatial layout of the archive storage area, creating corresponding spatial elements including floors and rooms in the BIM model to define the spatial boundaries of the archive storage area; for the equipment location of the archive storage, creating corresponding equipment families and equipment instances in the BIM model to define the spatial location of the equipment for the archive storage; for the pipeline direction of the archive storage, creating corresponding pipeline families and pipeline instances in the BIM model to define the spatial direction of the pipeline; and using the BIM model after defining the spatial boundaries, equipment spatial location and pipeline direction as the digital twin model of the archive storage area.
[0017] Furthermore, the metadata of the archive is generated, including: preprocessing the collected image, which includes image denoising, tilt correction and region segmentation; using the median filter algorithm to denoise the collected image, remove Gaussian noise and salt and pepper noise in the image, and obtain the denoised image; specifically, select a sliding window, usually a square window of odd size, such as 3×3, 5×5, etc. Slide the sliding window to each pixel position of the image in turn, extract all pixel values in the window, and arrange them in order of size. Select the middle value of the arranged pixel value sequence as the new value of the current pixel to replace the original pixel value. Repeat steps b and c until the entire image is traversed to obtain the denoised image. The median filter algorithm can effectively remove the salt and pepper noise in the image, and also has a certain inhibitory effect on Gaussian noise. Compared with linear filtering methods such as mean filtering, median filtering can better preserve the edge and detail information of the image.
[0018] The Hough transform algorithm is used to perform tilt correction on the denoised image, detect the straight line features in the image, calculate the tilt angle of the image, rotate the image, correct the tilt of the image, and obtain the tilt-corrected image; specifically, edge detection is performed on the image, edge pixels in the image are extracted, and a binary edge image is obtained. Common edge detection algorithms include Canny, Sobel, Prewitt, etc. The edge image is subjected to Hough transform to map the image space (x, y) to the parameter space (ρ, θ), where ρ represents the distance from the straight line to the origin, and θ represents the angle of the straight line. The transformation formula is: ρ = xcosθ + ysinθ. In the parameter space, each edge point (x, y) corresponds to a sine curve ρ = xcosθ + ysinθ. The sine curves corresponding to multiple collinear edge points in the parameter space will intersect at a certain point (ρ, θ) to form a peak point. Through the peak detection algorithm, the peak point (ρ) in the parameter space is found. max ,θ max ), which corresponds to the most likely straight line in the image space. According to the detected straight line angle θ max , calculate the image tilt angle α = 90°-θ max The image is rotated counterclockwise by an angle of α to correct the image tilt. The rotation transformation can be implemented using methods such as affine transformation or perspective transformation. The Hough transform algorithm can accurately detect the tilted straight line in the image and calculate the tilt angle, and then the image is rotated to obtain a horizontally or vertically aligned image.
[0019] The image after tilt correction is segmented by a segmentation algorithm based on region growing, and the text region in the image is extracted to obtain the text region image; one or more seed pixels are selected as the initial region, and usually the pixels in the image whose grayscale value is significantly different from the background are selected. For each seed point, check whether the grayscale value of its neighboring pixels meets the similarity criteria, such as the grayscale difference is less than the threshold, the gradient direction is consistent, etc. The neighboring pixels that meet the similarity criteria are merged into the current region and marked as visited. Similar pixels are repeatedly merged into the current region until no neighboring pixels that meet the conditions can be found. New unvisited pixels are selected as seed points, and the process is repeated until all pixels have been visited to obtain a complete region segmentation result. The segmented regions are post-processed, such as removing too small regions, merging adjacent similar regions, etc., to obtain the final text region. The region growing algorithm can adaptively segment different regions in the image according to the similarity of pixels, and is particularly suitable for extracting text regions in images. The text region usually has relatively uniform grayscale, gradient and other characteristics, and is significantly different from the background region, so it can be accurately segmented by the region growing algorithm.
[0020] A pre-trained OCR model based on a convolutional neural network is used to perform feature extraction on the preprocessed image, extract text features in the image, and decode and convert the text features into a text sequence; S33, structured processing is performed on the text features to generate metadata for the archive, which includes the title, author, creation date, and page number of the archive.
[0021] Furthermore, the text features in the image are extracted, and the text features are decoded and converted into a text sequence, including: inputting the preprocessed image into a pre-trained OCR model based on a convolutional neural network, extracting the text features in the image through a convolutional layer and a pooling layer, and obtaining a text feature vector sequence of dimension (T, N), wherein T is the length of the feature vector, and N is the dimension of the feature vector; inputting the extracted text feature vector sequence into the CTC layer of the OCR model, and using a forward-backward algorithm to calculate the conditional probability of the feature vector sequence, wherein the conditional probability represents the probability that the feature vector sequence generates a target text sequence; in the CTC layer, using a dynamic programming algorithm to recursively calculate the forward probability and the backward probability, and multiplying the forward probability and the backward probability to obtain the conditional probability of each character at each moment; using a CTC loss function to calculate the distance between the feature vector sequence and the target text sequence, and using a gradient descent algorithm to optimize the CTC loss function, and updating the parameters of the convolutional neural network and the CTC layer.
[0022] According to the optimized CTC layer parameters, the best path decoding algorithm is used to decode the feature vector sequence, and the path with the largest conditional probability is selected to generate the recognized text sequence; specifically, the best path decoding algorithm is applied after the CTC (Connectionist Temporal Classification) layer to decode the feature vector sequence output by the CTC layer into the final text sequence. The output of the CTC layer is a T×C feature vector sequence, where T represents the number of time steps and C represents the number of character categories (including blank characters). The feature vector of each time step represents the conditional probability distribution of the character category corresponding to the time step. The goal of the best path decoding algorithm is to find the path with the largest conditional probability among all possible character sequences as the final recognition result. More specific steps are as follows: define the best path and maximum probability. Initialize the best path to an empty string with a maximum probability of 1. Traverse the feature vector sequence output by the CTC layer, and for each time step t: find the character category c with the largest conditional probability at that time step. t ,Right now where y t is the eigenvector at time t. If c t is a blank character (denoted as "blank"),
[0023] Then skip this time step and continue to process the next time step. tIf it is the same as the last character of the best path, skip this time step and continue to process the next time step. This is to avoid consecutive repeated characters. Otherwise, append c t to the end of the best path and update the maximum probability to the current probability multiplied by the conditional probability of c t , that is, prob' = prob × y t [c t . Return the best path as the final recognition result. It can be seen that the best path decoding algorithm is a greedy algorithm that selects the locally optimal character each time and continuously expands the best path until the entire feature vector sequence is traversed. The time complexity of this algorithm is O(T), which is proportional to the length of the feature vector sequence, and it is simple and efficient to implement. Preferably, when selecting the best path, not only the output probability of the CTC layer is considered, but also the language model probability of the candidate character sequence, that is, P(W) = P ctc (W) × P lm (W) is the conditional probability output by the CTC layer, and P lm (W) is the prior probability given by the language model. The language model can provide information on the rationality and coherence of the character sequence and help correct the recognition errors of the CTC layer.
[0024] Furthermore, the forward probability calculation formula is: The forward probability calculation formula is:
[0025] The backward probability calculation formula is: When i < m,
[0026] When i = m,
[0027]
[0028] The conditional probability calculation formula is: p(i,t) = α(t,i) × β(t,i); where, t represents the time step, which is the position index in the feature vector sequence, and its value range is [1, T], where T is the length of the feature vector sequence. i represents the character index, which is the position index in the target character sequence, and its value range is [1, m], where m is the length of the target character sequence. α(t,i) represents the forward probability of the i-th character at time t, which is the probability of generating the first i characters in the target character sequence from the feature vector sequence before time t. β(t,i) represents the backward probability of the i-th character at time t, which is the probability of generating the character sequence after the i-th character in the target character sequence from the feature vector sequence after time t. represents the emission probability of the i-th character at time t, which is the probability of generating the i-th character in the target character sequence at time t, and is calculated by passing the output of the convolutional neural network through the softmax function. represents the emission probability of the i-th character at time t+1, and represents the probability of generating the i-th character in the target character sequence at time t+1, which is calculated by the output of the convolutional neural network through the softmax function. m represents the length of the target character sequence, and represents the number of characters contained in the character sequence to be recognized. p(i,t) represents the conditional probability of the i-th character at time t, and represents the probability of generating the i-th character in the target character sequence at time t, which is obtained by multiplying the forward probability α(t,i) and the backward probability β(t,i). T represents the length of the vector sequence, and represents the number of character feature vectors extracted by the convolutional neural network. N represents the dimension of the feature vector, and represents the length of each character feature vector.
[0029] Furthermore, an optimal storage solution for archives is generated, including: establishing a mapping relationship between the metadata of the archives and the digital twin model through a natural language algorithm, matching the title, author, creation date and page number of the archive in the metadata with the storage unit size and storage unit type in the digital twin model; setting constraints for archive storage according to the mapping relationship between the metadata of the archive and the digital twin model, the constraints include the spatial coordinates of the storage unit in the digital twin model, the size of the storage unit, the type of the storage unit and the size and type of the archive; using the constraints of archive storage as the limiting conditions, and taking access efficiency and space utilization as the optimization goals, using a genetic algorithm to calculate the optimal path for the archive from the storage to the target storage location; randomly generating an initial population, each individual represents a feasible path from the storage to the target storage location, and the gene encoding of the individual is a sequence of spatial coordinates of the storage units passed on the path; calculating the adaptation of each individual The fitness function takes access efficiency and space utilization as optimization goals. Access efficiency is measured by path length, and space utilization is measured by the filling rate of storage units on the path; the current population is selected, crossed and mutated to generate a new population; the roulette wheel selection algorithm is used to select excellent individuals to enter the mating pool in the form of probability according to the size of the individual's fitness function value; the sequential crossover algorithm is used to randomly select two parent individuals, cross the gene sequences of the two individuals at random positions, and generate two new offspring individuals; the uniform mutation algorithm is used to mutate each gene position of the offspring individual according to a certain probability, and the original gene is replaced by a randomly generated new gene; repeat until the preset number of iterations is reached or the termination condition is met, and the individual with the highest fitness function value is output as the optimal path; the optimal storage plan for the archive is generated according to the optimal path, and the optimal storage plan includes the spatial coordinates of the target storage unit.
[0030] Another aspect of the present application also provides a digital archive management system for executing a digital archive management of the present application.
[0031] Compared with the prior art, the advantages of this application are:
[0032] Three-dimensional laser scanning technology is used to obtain high-precision point cloud data of the archive storage area. Data processing is performed through voxel filtering, 4PCS registration, triangular mesh division and other algorithms. Problems such as high noise in point cloud data, difficult registration, and data redundancy are overcome, and three-dimensional digital reconstruction of the archive storage environment is achieved, laying a solid data foundation for the subsequent construction of archive digital twins.
[0033] By extracting physical information such as warehouse space boundaries, equipment locations, and pipeline directions, a digital twin model of archive storage is constructed. As a digital mirror of the physical space, the digital twin realizes the mapping and interconnection between the real archive warehouse and the virtual digital space, so that information such as the archive storage environment and the status of facilities and equipment can be dynamically presented in the digital space.
[0034] The OCR model based on convolutional neural network is used to perform text recognition on images of archive covers and catalogs. Through end-to-end text positioning and recognition, the problem of low accuracy of text extraction from archive images faced by traditional OCR methods is overcome, and the automatic and intelligent extraction of archive metadata is realized. At the same time, the extracted unstructured archive semantics are innovatively associated and mapped with the structured archive spatial location. The semantic information such as archive titles and keywords is analyzed through natural language understanding, and a mapping index is established with location information such as warehouse dimensions and spatial coordinates, which opens up the link between archive content retrieval and spatial positioning, realizes the multi-dimensional association and integrated utilization of archive information, and improves the efficiency and convenience of archive retrieval.
[0035] Based on the digital twin model, the spatial constraints and business needs of archive storage are comprehensively considered, and the intelligent solution of archive storage plan is realized through a multi-objective optimization model. Genetic algorithm is introduced, and the access efficiency and space utilization are used as optimization goals to search for the optimal storage path and spatial location in the archive storage and stacking process. Compared with the storage plan formulated by manual experience, this method can quickly search for the optimal solution in massive combinations, maximize the access efficiency while making reasonable use of space. BRIEF DESCRIPTION OF THE DRAWINGS
[0036] The present application will be further described in the form of exemplary embodiments, which will be described in detail by the accompanying drawings. These embodiments are not restrictive, and in these embodiments, the same number represents the same structure, wherein:
[0037] Figure 1 is an exemplary flow chart of a digital archive management method according to some embodiments of the present application;
[0038] Figure 2 is an exemplary flow chart of constructing a three-dimensional digital model of an archive storage area according to some embodiments of the present application;
[0039] Figure 3 is an exemplary flow chart of generating a text sequence according to some embodiments of the present application;
[0040] Figure 4 This is an exemplary flowchart for generating an optimal storage solution according to some embodiments of the present application. DETAILED DESCRIPTION
[0041] The method and system provided in the embodiments of the present application are described in detail below with reference to the accompanying drawings.
[0042] Figure 1 This is an exemplary flow chart of a digital archive management method shown in some embodiments of the present application, a digital archive management method, including: collecting point cloud data of the archive storage area through a three-dimensional laser scanner, the point cloud data is a set of discrete point set data including spatial coordinates (X, Y, Z); importing the point cloud data into three-dimensional modeling software, using voxel filtering to downsample and denoise the point cloud, and remove outliers and duplicate point data; using 4PCS algorithm to perform point cloud registration to achieve a coordinate system of multiple groups of point cloud data obtained by scanning from different perspectives; dividing the point cloud data into triangular mesh patches according to a consistency criterion to form closed three-dimensional mesh model data; calibrating the coordinates of the three-dimensional mesh model to extract the spatial coordinate data of the archive storage unit.
[0043] Import the 3D mesh model data obtained in the previous step into the BIM software, construct the archive building space entities such as floors and rooms in the BIM software, obtain the building space layout information, place the equipment models such as archive racks and compact shelving in the corresponding space, obtain the equipment location layout information, draw the electrical and fire protection pipeline facilities, obtain the pipeline layout direction information, associate and map the above physical space information with the 3D model, and build a digital twin model of the archive storage area. Collect the key page images of the archive cover, catalog page, etc. The image should contain the key information of the archive title, author, date, page number, etc.; pre-process the collected images, including image enhancement, tilt correction, region segmentation, etc., to improve the image quality; input the pre-processed image into the CNN-based OCR model for text detection and recognition; the OCR model outputs the text content in the image, extracts the key metadata such as the archive title, author, date, page number, etc.; the extracted metadata is structured to generate standardized archive attribute metadata.
[0044] Analyze the digital twin model data of archive attribute metadata and archive storage area; establish the semantic mapping relationship between archive metadata and archive storage unit attributes through natural language processing algorithm; match the archive size, type and other attributes with the corresponding storage unit size and type data according to the mapping relationship; build an archive storage optimization model with the spatial coordinates, size, type and other constraints of the archive storage unit and the archive access efficiency and space utilization as the optimization target; solve the optimization model using genetic algorithm to calculate the optimal storage path from the archive to the storage unit; output the optimal storage plan data containing the spatial coordinates of the best storage location of the archive. According to the optimal storage plan, store the archive in the target storage unit; create archive entities in the database and record the structured attribute metadata of the archive; store the archive's target storage location spatial coordinates in association with the corresponding relationship between the three-dimensional model coordinates and the actual spatial position; record the timestamp information of the archive storage; store archive metadata, storage location, timestamp and other information in association, and establish a mapping relationship between archive entities and archive management events.
[0045] Specifically, the three-dimensional point cloud data of the archive storage area is obtained, and the three-dimensional point cloud data is processed using three-dimensional modeling software to generate a three-dimensional digital model of the archive storage area, and the spatial coordinates of the archive storage area are extracted, including: using high-precision three-dimensional laser scanners such as Leica BLK360 to perform a full-scale scan of the archive storage area, with a scanning accuracy of up to 5mm, to obtain point cloud data containing tens of millions of three-dimensional points, each point containing XYZ coordinates and RGB color information; collecting point cloud data of the main building structures such as the ground, walls, ceilings, and columns of the archive warehouse. By scanning these structures, geometric information such as the spatial dimensions and layout direction of the warehouse is obtained, providing spatial boundaries and reference benchmarks for subsequent modeling. The integrity and detailed features of the structure, such as door and window openings, pipeline trough boxes, etc., need to be taken into account during the scanning. The point cloud data of various storage facilities such as archive racks, compact shelving, archive cabinets, and mobile shelves inside the archive warehouse are collected. The facilities are scanned with high precision to obtain information such as their three-dimensional dimensions, shapes, and spatial placement. The scanning needs to fully cover each storage unit, such as each layer of partitions in the compact shelving and each drawer of the archive cabinet.
[0046] Import the raw point cloud data obtained by scanning into 3D modeling software such as Geomagic Studio. Set the grid size of the voxel filter to 10mm, downsample the point cloud, and remove redundant points. Use the statistical filtering method to calculate the average distance from each point to its neighboring points, and remove outliers whose distance is greater than 2 times the standard deviation of the average distance. Set the minimum distance threshold between points to 5mm to remove duplicate points.
[0047] The 4PCS registration algorithm is used to perform spatial registration on the filtered 3D point cloud data, and the coordinates of the 3D point cloud data obtained by scanning at different angles are unified and merged into a complete 3D point cloud model; including: from the 3D point cloud data set after filtering, a group of point clouds is randomly selected as the reference point cloud, and the remaining point clouds are used as the point clouds to be registered. Taking the 10 groups of point cloud data obtained by scanning as an example, each group of point clouds contains about 5,000,000 points, the first group of point clouds is randomly selected as the reference point cloud, and the remaining 9 groups of point clouds are used as the point clouds to be registered.
[0048] In the reference point cloud, four non-coplanar points are randomly selected to form a basis set. Taking the selected points P1(x1,y1,z1), P2(x2,y2,z2), P3(x3,y3,z3), and P4(x4,y4,z4) as examples, the Euclidean distance between these four points is calculated, with a total of 6 distance values, forming a consistency descriptor vector:
[0049] [d 12 ,d 13 ,d 14 ,d 23 ,d 24 ,d 34 ]; where d ij Indicates point P i and point P j The distance between P1 and P2. 12 The calculation formula is: Through calculation, the consistent descriptor vector of the basic set is obtained as the basis for subsequent matching.
[0050] KD tree index construction, for the point cloud A to be registered, a KD tree index is constructed according to its three-dimensional coordinates. KD tree is a tree data structure that divides k-dimensional spatial data. It divides the point cloud into non-overlapping rectangular areas by recursively dividing the point cloud into two parts, and each area corresponds to a node of the tree. Taking the point cloud A to be registered containing 5,000,000 points as an example, a 3-layer KD tree is constructed, and each layer is divided according to the x, y, and z coordinates to obtain 8 leaf nodes, each of which contains about 600,000 points. The construction time complexity of the KD tree index is O(nlog(n)), and the space complexity is O(n), where n is the number of point clouds.
[0051] The nearest neighbor search uses the consistency descriptor of the reference point cloud basis set as the query vector and performs the nearest neighbor search in the kd tree index of the point cloud A to be registered. The consistency descriptor is a 6-dimensional vector containing the distance information between the 4 points in the basis set. Taking the consistency descriptor of the reference point cloud basis set as [0.5, 0.8, 1.2, 0.6, 1.0, 0.9] as an example, a recursive search starts at the root node of the kd tree, and the query vector is compared with the split dimension coordinate value of the current node. According to the comparison result, the left subtree or the right subtree is selected until the leaf node is reached. In the leaf node, a linear scan is used to calculate the Euclidean distance between the query vector and the consistency descriptor of each point in the node to find the candidate matching point with the smallest distance. Then backtrack to the parent node, compare the query vector with the split dimension coordinate value of the parent node, and determine whether it is necessary to enter another subtree for search. Repeat the recursive search process until the candidate matching basis set with the smallest distance to the query vector is found. The time complexity of the nearest neighbor search of the kd tree is O(log(n)) and the space complexity is O(n).
[0052] Candidate matching basis set selection, through nearest neighbor search, find the 10 candidate matching basis sets with the smallest distance to the consistency descriptor of the reference point cloud basis set in the point cloud to be registered A. Taking the first candidate matching basis set as an example, its consistency descriptor is [0.52, 0.83, 1.18, 0.58, 0.97, 0.92], and the Euclidean distance between the consistency descriptor of the reference point cloud basis set is 0.1, which is less than the set distance error threshold of 2mm. The four points P1'(x1',y1',z1'), P2'(x2',y2',z2'), P3'(x3',y3',z3'), and P4'(x4',y4',z4') of the candidate matching basis set correspond one-to-one to the four points P1(x1,y1,z1), P2(x2,y2,z2), P3(x3,y3,z3), and P4(x4,y4,z4) of the reference point cloud basis set, forming point pairs (P1,P1'), (P2,P2'), (P3,P3'), and (P4,P4').
[0053] Candidate matching basis set optimization, for the 10 candidate matching basis sets found, by calculating the distance error between each basis set and the reference point cloud basis set, select the candidate matching basis set with the smallest distance error as the optimal matching basis set. Taking the first candidate matching basis set as an example, calculate the distance error between its 4 points and the 4 points of the reference point cloud basis set:
[0054]
[0055]
[0056] The distance errors of the four points are all less than 0.2 mm, meeting the error requirements. The distance errors of the 10 candidate matching basis sets are compared, and the first candidate matching basis set has the smallest distance error and is selected as the optimal matching basis set. Through the kd-tree index and nearest neighbor search, the candidate matching basis set with the most similar geometry to the reference point cloud basis set is efficiently found in the point cloud to be registered, providing reliable corresponding point pairs for subsequent rigid body transformation.
[0057] Rigid body transformation matrix calculation and point cloud coordinate transformation, for each candidate matching basis set, the rigid body transformation matrix between it and the reference point cloud basis set is calculated by singular value decomposition (SVD) and other methods, including the rotation matrix R and translation vector t. Taking the candidate matching basis set B as an example, the rotation matrix R and translation vector t between B and the reference point cloud basis set are calculated by SVD to obtain a 4x4 transformation matrix: All points P in the point cloud A to be registered A Substitute (x, y, z) into the transformation matrix to get the transformed point P A' (x', y', z'), complete the rigid body transformation of point cloud A to the reference point cloud coordinate system. The transformation formula is: Through rigid body transformation, the point cloud A to be registered and the reference point cloud achieved preliminary registration, and the registration error was less than 5mm.
[0058] Selection of the optimal registration result: For all registered point clouds to be registered, calculate the registration error between them and the reference point cloud, and the error metric uses the root mean square error RMSE of the point-to-surface distance. Taking the registered point cloud A as an example, for each point in A, search for its nearest neighbor triangular facet in the reference point cloud, calculate the distance from the point to the facet, take the root mean square of all point-to-surface distances, and obtain the registration RMSE error of point cloud A, which is 1.5mm. Set the RMSE error threshold to 2mm, and select the registration result with an error less than the threshold as the candidate optimal registration result. By evaluating the registration results of the 9 point clouds to be registered, the registration result of point cloud C with the smallest registration error is selected as the optimal registration result, and its registration RMSE error is 1.2mm, which is significantly better than other registration results.
[0059] The coordinate system is fused with the point cloud. The rotation matrix R and translation vector t corresponding to the optimal registration result are applied to the point cloud C to be registered, and the coordinate system of C is converted to the coordinate system of the reference point cloud to achieve the unification of the coordinate system. The unified point cloud C and the reference point cloud are weighted fused. During the fusion, the weight coefficient is set according to the registration error of the point cloud. The smaller the registration error, the larger the weight coefficient. With the registration RMSE error of point cloud C and the reference point cloud as 1.2mm, the weight coefficient of point cloud C is set to 0.8, and the weight coefficient of the reference point cloud is set to 0.2. For the points at corresponding positions in point cloud C and the reference point cloud, weighted averaging is performed according to their respective weight coefficients to obtain the coordinates of the fused point cloud. The fused point cloud has the same coordinate system as the reference point cloud, and the geometric information of the two point clouds is fused to obtain a more complete and accurate three-dimensional point cloud model.
[0060] Point cloud model update: according to the fused point cloud coordinates, the reference point cloud model is updated to obtain the registered three-dimensional point cloud model. The updated model contains the geometric information of the original reference point cloud and the point cloud C to be registered, and the point cloud density and coverage are significantly improved. Using the updated model as the new reference point cloud, the remaining point clouds to be registered are repeatedly registered in sequence to finally obtain a complete three-dimensional point cloud model. The model contains the geometric information of 10 groups of point clouds, with a point cloud number of approximately 50,000,000. The registration error is controlled within 2mm, and the degree of consistency with the actual scene is high. Through the 4PCS registration algorithm, the local geometric features of the point cloud are used to achieve efficient and accurate point cloud registration, without the need to extract feature points or feature descriptors, and is suitable for point cloud data of large-scale and complex scenes. The registered point cloud model is further improved in integrity and accuracy through coordinate system unity and weighted fusion.
[0061] For the registered 3D point cloud model, the Euclidean distance between each point and its nearest neighbor is calculated to obtain the point spacing distribution of the point cloud model. Taking the registered point cloud model containing 10,000,000 points as an example, the kd tree algorithm is used to search the nearest neighbor of the point cloud. The 10 nearest neighbor points of each point are searched, and the average distance between the point and the neighbor points is calculated to obtain the point spacing of the point. By counting the point spacing of all points, the point spacing distribution histogram of the point cloud model is obtained. The average value of the point spacing is 5mm and the standard deviation is 1mm. The point spacing reflects the sampling density and resolution of the point cloud model. The smaller the point spacing, the higher the sampling density and the higher the accuracy of the triangular mesh division. For the registered 3D point cloud model, the normal vector and curvature of each point are calculated to reflect the local geometric features of the point cloud surface. Taking point P as an example, with P as the center and 3 times the point spacing as the radius, the neighborhood point set N of P is determined. Principal component analysis (PCA) is performed on the points in N to obtain 3 main directions and 3 eigenvalues. The first principal direction corresponds to the largest eigenvalue, indicating the direction of the normal vector of the neighborhood point set. The second and third principal directions correspond to the second largest and smallest eigenvalues, indicating the direction of the tangent plane of the neighborhood point set. The curvature of point P is calculated based on the three eigenvalues: Among them, λ1 and λ2 are the eigenvalues corresponding to the first and second principal directions respectively. The curvature K ranges from [0, 1]. The larger the curvature, the greater the local change of the point cloud surface. More mesh patches are needed to approximate the surface when the triangular mesh is divided. By calculating the curvature of all points, the curvature distribution diagram of the point cloud model is obtained. The average value of the curvature is 0.2 and the standard deviation is 0.1.
[0062] According to the point spacing and curvature distribution of the point cloud model, the Delaunay triangulation algorithm is used to divide the point cloud into triangular meshes. Delaunay triangulation is a triangulation algorithm based on the topological structure of the point cloud. It generates a triangular mesh with regular shape and nearly equilateral shape by maximizing the minimum angle of the triangle. Taking the average point spacing of the point cloud model as 5mm as a parameter, the maximum side length of the Delaunay triangulation is set to 5mm to limit the size of the triangular mesh. In the dense point cloud area, the side length of the triangular mesh is adaptively adjusted according to the curvature of the point. The larger the curvature, the smaller the side length, and more triangular facets are generated to approximate the point cloud surface. Through Delaunay triangulation, a triangular mesh of the point cloud model is generated, which contains 20,000,000 triangular facets. The average side length of the triangular facets is 4mm, which is equivalent to the sampling resolution of the point cloud. The normal vector of the triangular mesh has good continuity and can accurately represent the surface shape of the point cloud.
[0063] According to the topological structure and geometric information of the triangular mesh, a three-dimensional digital model of the archive storage area is generated. The three-dimensional digital model is based on the vertex coordinates and facet topology of the triangular mesh, and approximates the surface shape and texture details of the archive storage area through the normal vectors and texture coordinates of the triangular facets. Taking the triangular mesh model of the archive storage area as an example, each triangular facet contains the coordinates and normal vectors of 3 vertices, as well as the texture coordinates of 3 vertices. Through the rasterization algorithm, the geometric and texture information of the triangular facets are rendered to the screen space to generate a three-dimensional visualization model of the archive storage area. The data volume of the three-dimensional digital model is about 300MB, including 10,000,000 vertices and 20,000,000 triangular facets. It can be rendered in real time at a speed of 30 frames per second, meeting the needs of archive management and visualization.
[0064] The RANSAC algorithm is used to calibrate the coordinates of the three-dimensional digital model, extract feature points from the three-dimensional digital model, and select the four corner points on the top surface of the file box as feature points. Taking the file box size of 400mm×300mm×200mm as an example, the four corner points P1, P2, P3, and P4 on the top surface of the file box are manually selected in the three-dimensional digital model, and their three-dimensional coordinates (x1, y1, z1), (x2, y2, z2), (x3, y3, z3), and (x4, y4, z4) are extracted as control points for coordinate calibration.
[0065] According to the four extracted control points, the local coordinate system of the file box is established. With P1 as the origin of the coordinate system, the direction of P1P2 as the positive direction of the X axis, the direction of P1P4 as the positive direction of the Y axis, and the direction of the cross product of the X axis and the Y axis as the positive direction of the Z axis, a right-handed coordinate system is established. The coordinates of P2, P3, and P4 in the local coordinate system are calculated as (0, 300, 0), (400, 300, 0), and (0, 0, 200) as the target coordinates of the control points.
[0066] The RANSAC algorithm is used to calibrate the coordinates of the three-dimensional digital model and estimate the transformation parameters between the model coordinate system and the local coordinate system. RANSAC is a robust parameter estimation method that estimates model parameters through random sampling consistency, which can effectively eliminate erroneous corresponding points and improve estimation accuracy. The number of RANSAC iterations is set to 1000 times, and the inlier threshold is 10mm. In each iteration, three control points are randomly selected, the transformation matrix from the model coordinate system to the local coordinate system is calculated, the transformation matrix is applied to all control points, and the distance between the transformed control points and the target coordinates is calculated. The control points with a distance less than 10mm are regarded as inliers. Repeat the iteration 1000 times, select the transformation matrix with the largest number of inliers as the optimal estimation result, and use all inliers to re-estimate the transformation matrix to obtain the final coordinate transformation matrix.
[0067] The coordinates of the three-dimensional digital model are transformed into the local coordinate system using the estimated coordinate transformation matrix. Taking the model containing 15,000,000 vertices as an example, the coordinates of each vertex (x, y, z) are multiplied by the coordinate transformation matrix to obtain the transformed coordinates (x', y', z'), and the vertex coordinates are updated to complete the transformation from the model coordinate system to the local coordinate system. In the transformed model, the coordinates of the center of the top surface of the file box (200, 150, 200) are extracted as the spatial coordinates of the file box.
[0068] Evaluate the accuracy of the extracted spatial coordinates of the archive box, and calculate the error of coordinate extraction by comparing the difference between the extracted coordinates and the measured coordinates. Taking the measured center coordinates of the archive box as (198, 152, 201) as an example, the difference between the extracted coordinates and the measured coordinates is (2, -2, -1), the distance error is 3mm, and the relative error is 0.5%, which meets the accuracy requirements of archive space positioning. The spatial coordinates of 100 archive boxes were extracted and evaluated. The average distance error of coordinate extraction was 5mm, and the maximum error was 10mm. The accuracy meets the needs of archive space management.
[0069] Figure 2 This is an exemplary flow chart for constructing a three-dimensional digital model of an archive storage area according to some embodiments of the present application, and constructing a digital twin model of the archive storage area; including: importing the three-dimensional digital model of the archive storage area into BIM software, such as Autodesk Revit. Taking the three-dimensional digital model in OBJ format as an example, the model is imported into the BIM environment through the import function of Revit. The imported model contains 15,000,000 triangular facets, and the model size is 50m×30m×10m, which is consistent with the spatial size of the actual archive storage area. In Revit, the imported model can be adjusted in perspective, cut and analyzed, and the spatial structure and layout characteristics of the archive storage area can be intuitively understood.
[0070] In Revit, the BIM model of the archive storage area is constructed with reference to the imported 3D digital model. The BIM model is a parametric and intelligent building information model that contains the geometric information, attribute information and associated information of the building. Taking the archive storage area as an example, a project file is created in Revit, the project unit is set to millimeters, the elevation and reference plane are created, and the spatial coordinate system of the model is determined. According to the geometric features of the 3D digital model, the main structure model of the archive storage area is constructed using Revit's modeling tools, such as walls, columns, panels, doors and windows. For example, for the exterior wall of the archive storage area, a basic wall with a thickness of 200mm is created in Revit, and the surface of the 3D digital model is used as a reference for the wall to determine the spatial position and height of the wall. Through parametric modeling and instance modification, the spatial structure and component layout of the archive storage area are fully reproduced in the BIM model.
[0071] In the constructed BIM model, the physical space information of the archive storage facilities is extracted, including the spatial layout, equipment location and pipeline direction. For the spatial layout of the archive storage area, the corresponding floors and rooms are created in Revit to define the spatial boundaries of the archive storage area. Taking the first-floor archive room as an example, create the "first floor" floor in Revit with an elevation of 0, create rooms such as "Archive Room 1" and "Archive Room 2", and use the "Room Divider" tool to draw dividing lines along the room boundaries to generate the spatial boundaries of the rooms. Extract the spatial parameters of the room, such as area, volume, height, etc., and compare them with the spatial parameters of the three-dimensional digital model, with an error of less than 1%. For the location of the equipment for archive storage, create the corresponding equipment family and equipment instance in Revit to define the spatial location of the equipment. Taking the archive compact shelving as an example, create the "Archive Compact Shelving" equipment family in Revit, including family types such as columns, shelves, and baffles, and set family parameters such as size, material, load, etc. In the BIM model, load the "Archive Compact Shelving" equipment family into the project, and align the spatial position of the compact shelving with the three-dimensional digital model by modifying the instance properties, with a positioning error of less than 10mm. For the pipeline direction stored in the archive, create corresponding pipeline families and pipeline instances in Revit to define the spatial direction of the pipeline. Taking the water supply and drainage pipeline as an example, create "water supply pipe" and "drainage pipe" pipeline families in Revit, set family parameters such as pipe material, diameter, and connection method. In the BIM model, according to the pipeline position in the three-dimensional digital model, draw the pipeline instances of "water supply pipe" and "drainage pipe", and connect them through pipe fittings to form a complete pipeline system. Extract the spatial coordinates of the pipeline, and the deviation from the digital model is less than 50mm.
[0072] The BIM model after extracting the physical space information is used as the digital twin model of the archive storage area. Digital twin refers to the construction of a virtual copy of a physical entity in a digital space, and the dynamic association and real-time synchronization of the physical space and the virtual space are achieved through data mapping and interactive feedback. The BIM model contains the geometric information, attribute information and association information of the archive storage area, and is an ideal carrier for building digital twins. In Revit, the spatial elements, equipment instances, pipeline instances, etc. in the BIM model are matched one by one with the physical space to establish a mapping relationship of the digital twin. For example, the room element of "Archive Room 1" is associated with Archive Room 1 in the physical space, the equipment instance of "Archive Compact Shelves" is associated with the Compact Shelves in the physical space, and the pipeline instance of "Water Supply Pipe" is associated with the Water Supply Pipe in the physical space. Data exchange and state synchronization between the BIM model and the physical space are achieved through data interfaces and sensors. For example, a temperature and humidity sensor is installed in the physical space to collect the temperature and humidity data of the archive room in real time, and the temperature and humidity data is transmitted to the BIM model through the data interface, and the real-time temperature and humidity values are displayed in the room properties of "Archive Room 1". Modify the spatial position of the compact shelving in the BIM model, transmit the modification instructions to the physical space through the data interface, and control the movement and positioning of the compact shelving. Through the data mapping and interactive feedback between the BIM model and the physical space, a digital twin model of the archive storage area is constructed to achieve visual management and real-time monitoring of archive storage facilities.
[0073] Figure 3 This is an exemplary flow chart for generating a text sequence according to some embodiments of the present application, collecting archive cover and directory images, using an OCR model based on a convolutional neural network, recognizing the image through the ORC model, extracting the text content in the image, and generating archive metadata; including: denoising the collected archive cover and directory images, using a non-local mean denoising algorithm to remove Gaussian noise and salt and pepper noise in the image. Taking an archive cover image with a resolution of 3000×4000 as an example, the search window size of the denoising algorithm is set to 10×10, the similarity window size is 7×7, and the noise standard deviation is 15. After denoising, the signal-to-noise ratio of the image is improved by 5dB, and the image becomes clearer and smoother.
[0074] The de-noised image is tilted and corrected. A straight line detection algorithm based on Hough transform is used to detect the text line in the image, calculate the angle between the text line and the horizontal direction, and perform rotation correction on the image. Taking an archive directory image with a tilt angle of 5 degrees as an example, the distance resolution of the Hough transform is set to 1 pixel and the angle resolution is set to 0.1 degrees. 10 text line lines are detected, and the average tilt angle is calculated to be 4.8 degrees. The image is rotated 4.8 degrees counterclockwise. After correction, the text lines of the image are aligned, and the text tilt is basically eliminated.
[0075] Perform region segmentation on the image after skew correction. Adopt a text line segmentation algorithm based on projection profiles and a text region extraction algorithm based on connected components to segment the image into individual text lines and text regions. Taking an archive directory image containing 20 lines of text as an example, project the image horizontally to obtain a projection profile curve. Segment 20 text line regions according to the peak positions of the projection profile. Then perform vertical projection on each text line region to extract the connected components of the text, and finally obtain 120 text regions, each of which contains one or more characters.
[0076] Adopt a pre-trained OCR model based on a convolutional neural network to extract features from the preprocessed image, extract the text features in the image, and decode the text features into a text sequence; including: input the preprocessed image into the pre-trained OCR model, and use a convolutional neural network to extract the text features in the image. Taking a text line image with a size of 32×256 as an example, the OCR model adopts 6 convolutional layers and 2 pooling layers. The sizes of the convolutional kernels are 3×3, 3×3, 3×3, 3×3, 3×3, 3×3 in sequence, and the numbers of convolutional kernels are 64, 128, 256, 256, 512, 512 in sequence. The pooling layer adopts max pooling with a size of 2×2. After convolution and pooling, a feature map with a size of 1×32 is obtained, and the feature map is flattened into a feature vector sequence with a length of T = 32, and the dimension of the feature vector is N = 512.
[0077] Input the extracted text feature vector sequence into the CTC layer of the OCR model, and use the forward-backward algorithm to calculate the conditional probability of the feature vector sequence. Taking the recognition of "Example of Archive Title" as an example, the length of the target text sequence is m = 6. On the feature vector sequence of T = 32, use the dynamic programming algorithm to recursively calculate the forward probability α and the backward probability β: Let the position of the first feature vector be t = 1, and initialize the forward probability where represents the emission probability of generating the character "file" at t = 1, represents the emission probability of generating the character "archive", and so on; recursively calculate the forward probability, for example until α(32, 6) is calculated, that is, the forward probability of generating "Example of Archive Title" on all 32 feature vectors; Let the position of the last feature vector be t = 32, and initialize the backward probability β(32, 6) = 1, recursively calculate the backward probability, for example Until β(1, 1) is calculated, that is, the backward probability of generating "example of file title" on all 32 feature vectors; at each moment t and each character position i, calculate the conditional probability p(i, t)=α(t, i)×β(t, i) to obtain the conditional probability matrix P, with a size of 32×6, and P(t, i)=p(i, t) represents the conditional probability of generating the i-th character at moment t.
[0078] The CTC loss function is used to measure the distance between the conditional probability matrix P and the target character sequence. The CTC loss function is defined as: where x represents the sequence of character feature vectors, z represents the target character sequence, π represents all possible paths, and p(π|x) represents the probability of generating path π by the feature vector sequence. represents the probability of generating the target character sequence z, that is, the sum of the elements in the conditional probability matrix P. Taking the conditional probability matrix P as an example, set the learning rate of the CTC layer to 0.001, adopt the Adam optimization algorithm, iterate 100 times, minimize the CTC loss function, and update the parameters of the convolutional layer and the CTC layer to make the OCR model adapt to the current image sample and improve the accuracy of character recognition.
[0079] According to the optimized parameters of the CTC layer, use the best path decoding algorithm to decode the feature vector sequence, and select the path with the maximum conditional probability to generate the recognized character sequence. Taking the conditional probability matrix P as an example, using the best path decoding algorithm, select the character with the maximum conditional probability at each moment t to obtain the best path: when t = 1, select the character "档" corresponding to p(1, 1); when t = 2, select the character "案" corresponding to p(2, 2);...... when t = 32, select the character "例" corresponding to p(32, 6); connect the characters on the best path to obtain the recognized character sequence "example of file title", which completely matches the target character sequence and the recognition is correct.
[0080] Structural processing of text features to generate archive metadata: Structural processing of the identified text sequences, first merge the text sequences belonging to the same text line into a string. Taking the identified text sequences "Archive Title: "," Sample Contract "," Creation Date: "," March 1, 2023 "," Page 1, Total 10 Pages" as an example, according to the positional relationship of the text sequences, merge them into three strings: "Archive Title: Sample Contract "," Creation Date: March 1, 2023 "," Page 1, Total 10 Pages". Extract the key information of the archive from the merged string, and use regular expression matching and dictionary mapping methods to extract metadata such as the title, author, creation date and page number of the archive. For example, the title "Sample Contract" is extracted from "Archive Title: Sample Contract", the creation date "2023-03-01" is extracted from "March 1, 2023", and the starting page number "1" and the total number of pages "10" are extracted from "Page 1, Total 10 Pages". Organize the extracted key information into structured metadata according to the predefined format.
[0081] Figure 4 It is an exemplary flow chart for generating an optimal storage solution according to some embodiments of the present application, the metadata of the archive is associated with the digital twin model of the archive storage area, and the optimal path of the archive from the storage to the target storage location is calculated by using a genetic algorithm, with the spatial coordinates of the archive storage area as constraints, and with access efficiency and space utilization as optimization goals, to generate the optimal storage solution for the archive; including: establishing a mapping relationship between the metadata of the archive and the digital twin model through a natural language algorithm: using the named entity recognition technology in natural language processing, extracting page number information from the metadata of the archive, and calculating the total size of the archive according to the size standard of each page (such as A4, A3, etc.), and then matching it with the storage unit size in the digital twin model. For example, a 10-page A4 archive with a size of 210mm×297mm×10 is matched to a storage unit with a length of 300mm, a width of 220mm, and a height of 20mm in the digital twin model through a mapping relationship.
[0082] Using the keyword extraction technology in natural language processing, keywords such as title and creation date are extracted from the metadata of the archive, and matched to the storage unit type in the digital twin model according to the predefined correspondence rules between keywords and storage unit types. For example, archives containing the keyword "contract" in the title are matched to storage units of the contract type; archives with a creation date within three years are matched to storage units of the recent archive type.
[0083] According to the mapping relationship between the metadata of the archive and the digital twin model, set the constraints for archive storage, mainly including: Spatial coordinates of the storage unit: Each storage unit in the digital twin model has a unique spatial coordinate (x, y, z), which represents its position in three-dimensional space. The spatial coordinate is used as one of the constraints to ensure that the archive is stored in the specified storage unit. Dimensions of the storage unit: Each storage unit in the digital twin model has three size parameters: length, width, and height. The size of the storage unit must be greater than or equal to the size of the archive. As one of the constraints, ensure that the archive can be placed in the storage unit. Type of storage unit: Each storage unit in the digital twin model has a corresponding type, such as contract type, recent archive type, etc. The type of archive must match the type of storage unit. As one of the constraints, ensure that the archive is stored in the appropriate storage unit. Size and type of archive: The size and type of the archive are extracted from the metadata. As one of the constraints, ensure that the size and type of the archive matches the size and type of the storage unit.
[0084] Using genetic algorithm, we solve the optimal storage path. According to the mapping relationship between the metadata of the archive and the digital twin model, we set the constraints of archive storage as follows: Let the size of the archive be (l,w,h), where l is the length, w is the width, and h is the height; let the type of the archive be t, t∈{1,2,......,T}, where T is the total number of archive types. Let the spatial coordinates of the i-th storage unit in the digital twin model be (x i ,y i ,z i ), size (L i ,W i ,H i ), of type T i ,i∈{1,2,......,N}, where N is the total number of storage units. Then the constraints of archive storage can be expressed as: Storage unit size constraint: l≤L i ,w≤W i ,h≤H i ; Storage unit type constraint: t = T i ; Storage unit spatial coordinate constraints: 0≤x i ≤X max , 0≤y i ≤Y max , 0≤z i ≤Z max , where (X max ,Y max ,Z max ) are the spatial boundary coordinates of the digital twin model.
[0085] Taking access efficiency and space utilization as the optimization goals, the mathematical model is established as follows: Assume that the path length of the file from the storage to the i-th storage unit is d i, the space utilization of the i-th storage unit is r i , then the optimization goal can be expressed as: minimize the access path length: Maximize space utilization: Among them, d i It can be calculated based on the storage coordinates of the archive and the spatial coordinates of the i-th storage unit, r i It can be calculated based on the size of the file and the size of the i-th storage unit, that is,
[0086] Genetic algorithm is used to calculate the optimal path from the storage to the target storage location. Chromosome encoding encodes each possible storage path into a chromosome. The chromosome consists of N genes, and each gene represents the spatial coordinates (x i ,y i ,z i ). The value range of the gene is [0,X max ]、[0,Y max ]、[0,Z max ], respectively representing the three-dimensional coordinate range of the storage unit in the digital twin model. For example, a chromosome can be represented as [(1.2, 3.4, 5.6), (7.8, 9.0, 1.2), …, (2.3, 4.5, 6.7)], indicating that the file passes through these N storage units in sequence and finally reaches the target storage location.
[0087] Initial population generation: randomly generate M chromosomes as the initial population. The value of M is generally 20 to 100, which can be determined according to the complexity of the problem and computing resources. The gene value of each chromosome is encoded with floating point numbers.
[0088] [0,X max ]、[0,Y max ]、[0,Z max ] range. For example, you can use the rand() function to generate a random number between [0, 1] and then multiply it by X max ,Y max ,Z max , and get the random value of the three-dimensional coordinate. The initial population should cover the solution space as much as possible to ensure the diversity of the population and provide a good foundation for subsequent evolution.
[0089] Fitness function design,Genetic algorithm uses fitness function to evaluate the quality of each chromosome. The fitness function converts the optimization goal into a numerical value. The larger the value, the better the chromosome. According to the two optimization goals of the archive storage problem, the fitness function is designed as: in, Indicates the storage path length corresponding to the chromosome, d iIt can be calculated based on the spatial coordinates of two adjacent genes on the chromosome, that is, Represents the sum of the space utilization of the storage units corresponding to the chromosome, Where (l,w,h) is the size of the file, (L i ,W i ,H i ) is the size of the i-th storage unit; w1 and w2 are weight coefficients, satisfying w1+w2=1, indicating the relative importance of access efficiency and space utilization, which can be set according to actual needs.
[0090] Selection operator, using roulette selection operator to select excellent chromosomes. The basic idea of roulette selection is: normalize the fitness values of all chromosomes to obtain the selection probability of each chromosome. The chromosome with a larger selection probability is more likely to be selected. The specific steps are as follows: Calculate the fitness value F of each chromosome i ,i=1,2,......,M. Calculate the selection probability of each chromosome A number r is randomly generated in the range [0, 1]. If r < P1, the first chromosome is selected; otherwise, the kth chromosome is selected, where k satisfies Repeat M times to obtain M chromosomes as parents.
[0091] Crossover operator uses a two-point crossover operator to generate new daughter chromosomes. The basic idea of two-point crossover is to randomly select two crossover points, exchange some gene fragments of the two parent chromosomes, and generate two new daughter chromosomes. The specific steps are as follows: pair the M parent chromosomes in pairs to obtain M / 2 pairs of parent chromosomes. For each pair of parent chromosomes, randomly generate two crossover points p1 and p2, satisfying 1≤p1≤p2≤N. Exchange the gene fragments between p1 and p2 of the two parent chromosomes to obtain two daughter chromosomes. Repeat M / 2 times to obtain M daughter chromosomes.
[0092] Mutation operator, uniform mutation operator is used to maintain the diversity of the population. The basic idea of uniform mutation is: mutate each gene of the chromosome with a certain probability, and the mutated gene value is randomly generated within its definition domain. The specific steps are as follows: Set the mutation probability P m , usually 0.001 to 0.1. For each gene of each chromosome of each daughter, generate a random number r between [0, 1]. If r < P m , then the gene is mutated. The mutation operation is: in the gene value range [0,X max ]、[0,Y max ]、[0,Z max] and randomly generate a new value to replace the original gene value. Repeat until all genes of all offspring chromosomes have completed the mutation operation.
[0093] Termination condition, set the maximum number of iterations T or fitness threshold F t As the termination condition, when the maximum number of iterations is reached or the average fitness value of the population reaches the threshold, the algorithm terminates. The specific steps are as follows: set the maximum number of iterations T, generally 100 to 1000; or set the fitness threshold F t , represents the expected fitness level. In each iteration, the average fitness value of the population is calculated If the current iteration number reaches T or F avg ≥F t , the algorithm is terminated and the chromosome with the highest fitness value is output as the optimal solution; otherwise, the iteration continues.
[0094] According to the calculation results of the genetic algorithm, the chromosome with the highest fitness value can be obtained, which is decoded into the optimal storage path of the archive and the related optimization value. The expression of the optimal storage path is set as X. best , which contains N genes, each gene represents the spatial coordinates of a storage unit on the path, then the optimal storage path P best It can be expressed as: best =[(x1,y1,z1),(x2,y2,z2),...,(x N ,y N ,z N )]; where (x i ,y i ,z i ) is the spatial coordinate of the i-th storage unit, i = 1, 2, ..., N. The spatial coordinate of the target storage unit, the target storage unit is the optimal storage path P best The last storage unit of , its spatial coordinates can be expressed as:
[0095] (x t ,y t ,z t )=(x N ,y N ,z N ); where (x t ,y t ,z t ) is the spatial coordinate of the target storage unit, (x N ,y N ,z N ) is P bestThe spatial coordinates of the last storage unit in . The optimization value of access efficiency. The optimization goal of access efficiency is to minimize the length of the storage path. Its optimization value can be expressed as:
[0096] Among them, d i P best The distance between the i-th storage unit and the i-1-th storage unit, i = 1, 2, ..., N, (x0, y0, z0) is the storage coordinate of the file. The optimization value of space utilization, the optimization goal of space utilization is to maximize the sum of the space utilization of storage units, and its optimization value can be expressed as: Among them, r i P best The space utilization rate of the i-th storage unit, (l,w,h) is the size of the file, (L i ,W i ,H i ) is the size of the i-th storage unit, i = 1, 2, ....., N. The fitness value of the optimal solution, let the optimal solution X best The fitness value is F best , then F best It can be expressed as: Among them, w1 and w2 are weight coefficients, satisfying w1+w2=1, indicating the relative importance of access efficiency and space utilization.
[0097] According to the optimal storage plan for the archive, the archive is stored in the target storage location, and the structured metadata, storage location and timestamp of the archive are associated and stored in the database. Specifically, according to the optimal storage plan for the archive obtained by the genetic algorithm, the archive is stored in the spatial coordinates (x t ,y t ,z t) at the storage location. In specific implementation, the archives can be transported from the storage location to the target storage location by automated equipment such as robots, AGV carts, and conveyor lines. During the transportation process, identification technologies such as RFID and QR codes can be used to track and locate the archives in real time to ensure that the archives arrive at the designated location accurately. At the same time, visual recognition, sensors and other technologies can also be used to detect the size, weight, status, etc. of the archives in real time to avoid damage or loss of the archives during storage. When the archives are stored in the warehouse, the attribute information of the archives needs to be collected and extracted to form structured metadata. Metadata usually includes descriptive information such as the title, author, time, keywords, classification number, and storage period of the archives, as well as physical feature information such as the format, size, and number of pages of the archives. Metadata extraction can be achieved through manual entry, OCR recognition, voice recognition, etc., or by parsing the electronic file format of the archives to automatically extract relevant attribute information. The extracted metadata is stored in a structured format such as XML and JSON to facilitate subsequent retrieval and management. After the archives are stored in the target location, a timestamp needs to be generated to record the storage time of the archives. Timestamps are usually expressed in UTC format, accurate to the millisecond level, such as "2023-05-10T12:34:56.789Z". Timestamps can be generated by using the time functions provided by the operating system, such as C++'s chrono library, Java's System.current Time Millis(), etc., or by obtaining standard time through an external time server. The generated timestamp needs to be associated with the archive's metadata and storage location and stored in the database together. Associate the archive's structured metadata, storage location coordinates, and entry timestamp, and store them in the database for unified management. Associative storage can use a relational database (such as MySQL, Oracle, etc.) or a non-relational database (such as MongoDB, Elasticsearch, etc.).
[0098] In order to improve the retrieval efficiency of the database, you can create indexes for commonly used query fields. For example, you can create full-text indexes for fields such as title, author, and keyword to speed up keyword retrieval of archives; create a B+ tree index for the timestamp field to speed up time range queries of archives; and create a spatial index for the coordinate field to speed up location retrieval of archives. Indexes can be created using the index functions provided by the database, such as the CREATE INDEX statement of MySQL, or using the index interface provided by the search engine, such as the Mapping API of Elasticsearch.
[0099] When multiple users access the database concurrently, it is necessary to perform concurrency control on the associated stored procedures to avoid problems such as data inconsistency or deadlock. Concurrency control can adopt two strategies: pessimistic locking or optimistic locking. Pessimistic locking explicitly locks database resources to prevent modifications by other transactions, and is suitable for scenarios with a large number of concurrent writes; optimistic locking uses mechanisms such as version numbers or timestamps to detect whether data has been modified by other transactions, and is suitable for scenarios with a large number of concurrent reads. In specific implementation, you can use the lock mechanism provided by the database, such as MySQL's FOR UPDATE statement, or use the lock mechanism at the application layer, such as Redis's SETNX command.
Claims
1. A digital archive management method, characterized in that: include: Obtaining three-dimensional point cloud data of the archive storage area, processing the three-dimensional point cloud data using three-dimensional modeling software, generating a three-dimensional digital model of the archive storage area, and extracting the spatial coordinates of the archive storage area; Import the three-dimensional digital model of the archive storage area into the BIM software, associate and map the physical space information of the archive storage area with the three-dimensional digital model, and build a digital twin model of the archive storage area; Collect the cover and catalog images of the archives, use the OCR model based on convolutional neural network, recognize the images through the ORC model, extract the text content in the images, and generate the metadata of the archives; The metadata of the archives is associated with the digital twin model of the archive storage area. Using genetic algorithms, the spatial coordinates of the archive storage area are used as constraints, and the access efficiency and space utilization are used as optimization goals. The optimal path from the archive entry to the target storage location is calculated to generate the optimal storage plan for the archives. According to the optimal storage plan for the archives, the archives are stored in the target storage location, and the structured metadata, storage location and timestamp of the archives are associated and stored in the database.
2. The digital archive management method according to claim 1, characterized in that: Generate a 3D digital model of the archive storage area, including: Use a 3D laser scanner to scan the archive storage area to obtain 3D point cloud data of the archive storage area; Import the 3D point cloud data into the 3D modeling software, use the voxel filtering method to downsample and denoise the 3D point cloud data, and remove outliers and duplicate points in the 3D point cloud data; The 4PCS registration algorithm is used to perform spatial registration on the filtered 3D point cloud data, unify the coordinates of the 3D point cloud data scanned at different angles, and merge them into a complete 3D point cloud model; The registered 3D point cloud model is triangulated, and according to the point spacing and curvature of the 3D point cloud model, the Delaunay triangulation algorithm is used to generate the mesh surface of the 3D point cloud model, and the 3D digital model of the archive storage area is generated; The RANSAC algorithm is used to calibrate the coordinates of the three-dimensional digital model and extract the spatial coordinates of the archive storage in the three-dimensional digital model.
3. The digital archive management method according to claim 2, characterized in that: The 4PCS registration algorithm is used to perform spatial registration on the filtered 3D point cloud data, unify the coordinates of the 3D point cloud data scanned at different angles, and merge them into a complete 3D point cloud model, including: From the filtered 3D point cloud data, a group of point cloud data is randomly selected as the reference point cloud, and the remaining point cloud data is used as the point cloud to be registered; Randomly select 4 non-coplanar points in the reference point cloud to form a basis set, and calculate the consistency descriptor of the basis set. The consistency descriptor contains the distances between the 4 points. In each point cloud to be registered, the kd tree algorithm is used to perform the nearest neighbor search to obtain the candidate matching basis set with the smallest distance to the consistent descriptor of the basis set; Calculate the rigid body transformation matrix between each candidate matching basis set and the basis set, transform the coordinates of all points in the point cloud to be registered according to the rigid body transformation matrix, and obtain the registered three-dimensional point cloud; The registered 3D point cloud and the reference point cloud are unified in coordinates and merged into a complete 3D point cloud model.
4. The digital archive management method according to claim 3 is characterized in that: The registered 3D point cloud and the reference point cloud are unified to form a complete 3D point cloud model, including: Calculate the registration error between the registered 3D point cloud and the reference point cloud, select the optimal registration result with a registration error less than the error threshold by setting an error threshold, and obtain the rigid body transformation matrix corresponding to the optimal registration result as the optimal rigid body transformation matrix; Using the optimal rigid body transformation matrix, the coordinate system of the registered three-dimensional point cloud is converted to the coordinate system of the reference point cloud to achieve coordinate system one; Perform weighted fusion on the three-dimensional point cloud after the coordinate system is unified, set the weight coefficient according to the registration error of the point cloud, and calculate the coordinates of the fused three-dimensional point cloud; According to the fused 3D point cloud coordinates, the reference point cloud is updated to obtain the registered 3D point cloud model.
5. The digital archive management method according to claim 3 is characterized by: Build a digital twin model of the archive storage area, including: Import the 3D digital model of the archive storage area into the BIM software to build a BIM model of the archive storage area; In the BIM model, the physical space information of the archive storage facilities is extracted, which includes the spatial layout of the archive storage area, the location of equipment, and the direction of pipelines; For the spatial layout of the archive storage area, create corresponding spatial elements including floors and rooms in the BIM model to define the spatial boundaries of the archive storage area; For the equipment location of archive storage, create corresponding equipment families and equipment instances in the BIM model to define the equipment space location of archive storage; For the pipeline directions stored in the archive, create corresponding pipeline families and pipeline instances in the BIM model to define the spatial directions of the pipelines; The BIM model that defines the spatial boundaries, equipment spatial location and pipeline directions will be used as the digital twin model of the archive storage area.
6. The digital archive management method according to claim 5, characterized in that: Generate metadata for archives, including: Preprocess the collected images, including image denoising, tilt correction and region segmentation; Use a pre-trained OCR model based on a convolutional neural network to perform feature extraction on the pre-processed image, extract text features from the image, and decode the text features into a text sequence; The text features are structured to generate the archive's metadata, which includes the archive's title, author, creation date and page number.
7. The digital archive management method according to claim 6, characterized in that: Decode the text features into a text sequence, including: The preprocessed image is input into the pre-trained OCR model based on convolutional neural network, and the text features in the image are extracted through the convolution layer and pooling layer to obtain a text feature vector sequence with a dimension of TxN, where T is the length of the feature vector and N is the dimension of the feature vector; The extracted text feature vector sequence is input into the CTC layer of the OCR model, and the conditional probability of the feature vector sequence is calculated using the forward-backward algorithm. The conditional probability represents the probability that the feature vector sequence generates the target text sequence. In the CTC layer, the dynamic programming algorithm is used to recursively calculate the forward probability and the backward probability, and the forward probability and the backward probability are multiplied to obtain the conditional probability of each word at each moment; The CTC loss function is used to calculate the distance between the feature vector sequence and the target text sequence, and the gradient descent algorithm is used to optimize the CTC loss function and update the parameters of the convolutional neural network and CTC layer; According to the optimized CTC layer parameters, the best path decoding algorithm is used to decode the feature vector sequence, and the path with the largest conditional probability is selected to generate the recognized text sequence.
8. The digital archive management method according to claim 7, characterized in that: The forward probability calculation formula is: The backward probability calculation formula is: When i < m, When i=m, The conditional probability calculation formula is: p(i,t)=α(t,i)×β(t,i); Where t represents the time; i represents the character index; α(t,i) represents the forward probability of the i-th character at time t; β(t,i) represents the backward probability of the i-th character at time t; represents the probability of transmitting the i-th word at time t; represents the emission probability of the i-th character at time t+1; m represents the length of the target character sequence, which represents the number of characters contained in the character sequence to be recognized; p(i,t) represents the conditional probability of the i-th character at time t, which is obtained by multiplying the forward probability α(t,i) and the backward probability β(t,i); T represents the length of the feature vector sequence, which represents the number of character feature vectors extracted by the convolutional neural network; N represents the dimension of the feature vector, which represents the length of each character feature vector.
9. The digital archive management method according to any one of claims 2 to 7, characterized in that: Generate the optimal storage solution for archives, including: A mapping relationship between the archive metadata and the digital twin model is established through a natural language algorithm, and the title, author, creation date and page number of the archive in the metadata are matched with the storage unit size and storage unit type in the digital twin model; where the storage unit represents the spatial unit used to store archives in the archive storage area; According to the mapping relationship between the metadata of the archive and the digital twin model, set the constraints for archive storage. The constraints include the spatial coordinates of the storage unit in the digital twin model, the size of the storage unit, the type of the storage unit, and the size and type of the archive. Taking the constraints of archive storage as the limiting conditions, access efficiency and space utilization as the optimization goals, a genetic algorithm is used to calculate the optimal path from archive entry to the target storage location; An optimal storage plan for the archive is generated according to the optimal path, and the optimal storage plan includes the spatial coordinates of the target storage unit.
10. A digital archive management method system, characterized in that: include: At least one processing unit; used to execute instructions to implement the archive digital management method described in any one of claims 1 to 9.
Citation Information
Patent Citations
Drawing file management method and system based on BIM (Building Information Modeling) and Internet of Things
CN113536023A
Virtual file interaction method and system and electronic equipment
CN115599258A
Material management method and system based on digital twinning
CN116205561A
OCR (Optical Character Recognition) method for production logging-oriented archival data
CN118587719A
Intelligent book positioning and sorting system and method based on virtual reality enhancement technology
CN118952236A
Cited By
File digital processing method, device, equipment, medium and product
CN120071376A
Material detection method and system for material stacking area, medium and product
CN120356148A
Real estate archive digital quality management method based on full-process intelligent verification
CN120953133A