CN115470598B - Multithreading-based three-dimensional rolled piece model block data rapid inheritance method and system - Google Patents
Multithreading-based three-dimensional rolled piece model block data rapid inheritance method and system Download PDFInfo
- Publication number
- CN115470598B CN115470598B CN202211365563.1A CN202211365563A CN115470598B CN 115470598 B CN115470598 B CN 115470598B CN 202211365563 A CN202211365563 A CN 202211365563A CN 115470598 B CN115470598 B CN 115470598B
- Authority
- CN
- China
- Prior art keywords
- rolled piece
- model
- node
- block
- data
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Active
Links
Images
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F30/00—Computer-aided design [CAD]
- G06F30/10—Geometric CAD
- G06F30/17—Mechanical parametric or variational design
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F30/00—Computer-aided design [CAD]
- G06F30/20—Design optimisation, verification or simulation
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06T—IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06T17/00—Three dimensional [3D] modelling, e.g. data description of 3D objects
- G06T17/20—Finite element generation, e.g. wire-frame surface description, tesselation
- G06T17/205—Re-meshing
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F2111/00—Details relating to CAD techniques
- G06F2111/10—Numerical modelling
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F2119/00—Details relating to the type or aim of the analysis or the optimisation
- G06F2119/18—Manufacturability analysis or optimisation for manufacturability
-
- Y—GENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
- Y02—TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
- Y02P—CLIMATE CHANGE MITIGATION TECHNOLOGIES IN THE PRODUCTION OR PROCESSING OF GOODS
- Y02P90/00—Enabling technologies with a potential contribution to greenhouse gas [GHG] emissions mitigation
- Y02P90/30—Computing systems specially adapted for manufacturing
Landscapes
- Physics & Mathematics (AREA)
- Engineering & Computer Science (AREA)
- Theoretical Computer Science (AREA)
- Geometry (AREA)
- General Physics & Mathematics (AREA)
- Computer Hardware Design (AREA)
- Evolutionary Computation (AREA)
- General Engineering & Computer Science (AREA)
- Software Systems (AREA)
- Computer Graphics (AREA)
- Computational Mathematics (AREA)
- Mathematical Analysis (AREA)
- Mathematical Optimization (AREA)
- Pure & Applied Mathematics (AREA)
- Management, Administration, Business Operations System, And Electronic Commerce (AREA)
Abstract
The invention provides a multithreading-based three-dimensional rolled piece model block data rapid inheritance method and system, and relates to the technical field of rolling numerical simulation. The method comprises the following steps: and successively inheriting and transmitting the model data according to the steps of grid model reconstruction, model blocking and multithreading node data searching and calculating. Model partitioning can shorten search time by reducing the scope of searching nodes; the use of multiple threads puts tasks occupying a long time in a program into a background for processing, so that a user interface can respond to user operation more quickly, the calculation efficiency can be greatly improved, and the calculation time is reduced. The scheme provided by the invention greatly improves the data inheritance speed, better reflects the model data distribution before inheritance, and can obtain a simulation result with less error by carrying out subsequent calculation on the model inherited by the method.
Description
Technical Field
The invention relates to the technical field of rolling numerical simulation, in particular to a multithreading-based method and a multithreading-based system for quickly inheriting data of three-dimensional rolled piece model blocks.
Background
In the rolling process, the metal deformation is large, serious grid distortion can occur along with the simulation, and if finite element simulation is continued by using the distorted grid, a solution with large error or even an error which cannot be calculated can occur.
After the grid distortion occurs, the simulation needs to be suspended and the grid reconstruction needs to be performed. Inheritance and transmission of data information such as temperature, stress, strain and the like during reconstruction are important factors for restricting simulation precision, and if an inverse distance weighted average method is directly used for data transmission, a large amount of time is consumed, and subsequent calculation is seriously influenced.
Disclosure of Invention
The invention provides a multithreading-based method and a multithreading-based system for quickly inheriting block data of a three-dimensional rolled piece model, which are used for solving the problems that in the prior art, a large amount of time is consumed and subsequent calculation is seriously influenced because a reverse distance weighted average method is directly used for data transmission.
In order to solve the technical problems, the invention provides the following technical scheme:
on one hand, the method for quickly inheriting the block data of the three-dimensional rolled piece model based on multithreading is provided, and is applied to electronic equipment, and comprises the following steps:
s1: preprocessing an original rolled piece model by adopting a model partitioning method;
s2: obtaining a preprocessed rolled piece model, and carrying out grid reconstruction on the rolled piece model to obtain a new rolled piece model which has the same length and section shape as the original rolled piece model and is different from grids;
s3: dividing an original rolled piece model into a plurality of blocks along the length direction, and setting a search radius R according to the length of each block;
s4: judging the search radius R and the position from the target node to the block edge, and determining a search position; presetting a data output condition, and outputting node numbers and node data meeting the condition;
s5: and traversing and calculating each node in the new rolled piece model, obtaining the data distribution of the new rolled piece model after the multithreading calculation is finished, and finishing the fast inheritance of the block data of the multithreading-based three-dimensional rolled piece model.
Optionally, step S2 further includes: and by setting multi-thread parallel execution, the new rolled piece model is processed in blocks.
Optionally, in step S3, dividing the original rolled piece model into a plurality of blocks along the length direction, and setting a search radius R according to the length of each block, including:
dividing the number of blocks of the original rolled piece model according to the length of the rolled piece and the size of the grid; and the length of each part is a calculated value according to the length of the rolled piece and the set division parts, and the preset value of the search radius R is carried out according to the division length.
Optionally, in step S4, the method further includes: and the target unit is a unit formed by a plurality of target nodes.
Optionally, in step S4, the search radius and the position from the target node to the block edge are determined, and the search position is determined; presetting a data output condition, and outputting a node number and node data meeting the condition, wherein the method comprises the following steps of:
s41: determining that the search range is a whole ball by judging the block position of the search ball of the target node or the target unit corresponding to the original rolled piece model;
s42: judging the distance d from the target node to the left edge of the block 1 The size of (d); judging the distance d from the target node to the right edge of the block 2 According to the search radius R and the distance d 1 And a distance d 2 Determining a search position;
s43: and presetting a data output condition, calculating by using an inverse distance weighted average formula, and outputting the node number and the node data meeting the condition.
Optionally, in step S42, the distance d is determined according to the search radius R 1 And a distance d 2 Determining a search location, comprising:
if R is less than or equal to d 1 And R is not more than d 2 If the search range is limited to the target node or the block corresponding to the target unit; if R is>d 1 Or R>d 2 Then a search needs to be performed at the target node or at a block adjacent to the block where the target unit is located.
Optionally, in step S43, presetting a data output condition, calculating by using an inverse distance weighted average formula, and outputting a node number and node data that satisfy the condition, including:
the self-distance D in the searched sub-block corresponding to the target node i Node number N smaller than search radius R i And node data are output, wherein D i >0; and calculating by using an inverse distance weighted average formula, wherein the calculation result is the data of the target node or the target unit.
In one aspect, a multithreading-based three-dimensional rolled piece model block data fast inheritance system is provided, and is applied to electronic equipment, and the system comprises:
the model preprocessing module is used for preprocessing an original rolled piece model by adopting a model partitioning method;
the grid reconstruction module is used for obtaining a preprocessed rolled piece model and carrying out grid reconstruction on the rolled piece model to obtain a new rolled piece model which has the same length and section shape as the original rolled piece model and is different in grid;
the search radius determining module is used for dividing the original rolled piece model into a plurality of blocks along the length direction and setting a search radius R according to the length of each block;
the calculation module is used for judging the search radius R and the position from the target node to the block edge to determine a search position; presetting a data output condition, and outputting node numbers and node data meeting the condition;
and the traversing module is used for traversing and calculating each node in the new rolled piece model, obtaining the data distribution of the new rolled piece model after the multithreading calculation is finished, and finishing the fast inheritance of the data of the multithreading-based three-dimensional rolled piece model block.
Optionally, the model preprocessing module is configured to perform block processing on the new rolled piece model by setting multi-thread parallel execution.
Optionally, the grid reconstruction module is configured to divide the number of blocks of the original rolled piece model according to the length of the rolled piece and the size of the grid; and the length of each part is a calculated value according to the length of the rolled piece and the set divided parts, and the preset size of the search radius R is carried out according to the divided length.
In one aspect, an electronic device is provided, and the electronic device comprises a processor and a memory, wherein the memory stores at least one instruction, and the at least one instruction is loaded and executed by the processor to implement the multithreading-based three-dimensional rolled piece model block data fast inheritance method.
In one aspect, a computer-readable storage medium is provided, and at least one instruction is stored in the storage medium and loaded and executed by a processor to implement the multithreading-based three-dimensional rolled piece model block data fast inheritance method.
The technical scheme of the embodiment of the invention at least has the following beneficial effects:
in the scheme, the invention provides a method for quickly inheriting the data information of temperature, stress, strain and the like of the grid model with distortion after rolling into the re-planned grid model. And successively inheriting and transmitting the model data according to the steps of grid model reconstruction, model blocking and multithreading node data searching and calculating. Model partitioning can shorten search time by reducing the scope of searching nodes; the use of multithreading puts tasks occupying a long time in a program into a background for processing, so that a user interface can respond to user operation more quickly, the calculation efficiency can be greatly improved, and the calculation time is reduced. The data inheritance speed is greatly improved, the distribution of model data before inheritance is better reflected, and a simulation result with smaller error can be obtained by carrying out subsequent calculation on the model inherited by the method.
Drawings
In order to more clearly illustrate the technical solutions in the embodiments of the present invention, the drawings needed to be used in the description of the embodiments will be briefly introduced below, and it is obvious that the drawings in the following description are only some embodiments of the present invention, and it is obvious for those skilled in the art to obtain other drawings based on these drawings without creative efforts.
FIG. 1 is a flowchart of a multithreading-based fast inheritance method for block data of a three-dimensional rolled piece model according to an embodiment of the present invention;
FIG. 2 is a flowchart of a multithreading-based fast inheritance method for block data of a three-dimensional rolled piece model according to an embodiment of the present invention;
FIG. 3 is a schematic diagram of a model block of a multithreading-based fast inheritance method for three-dimensional rolled piece model block data according to an embodiment of the present invention;
FIG. 4 is a distorted grid temperature model diagram of a multithreading-based fast inheritance method for three-dimensional rolled piece model block data according to an embodiment of the present invention;
FIG. 5 is a grid temperature model diagram after data inheritance and grid reconstruction of a multithreading-based fast three-dimensional rolled piece model block data inheritance method provided by an embodiment of the present invention;
FIG. 6 is a block diagram of a multithreading-based fast inheritance system for block data of a three-dimensional rolled piece model according to an embodiment of the present invention;
fig. 7 is a schematic structural diagram of an electronic device according to an embodiment of the present invention.
Detailed Description
In order to make the technical problems, technical solutions and advantages of the present invention more apparent, the following detailed description is given with reference to the accompanying drawings and specific embodiments.
The embodiment of the invention provides a multithreading-based three-dimensional rolled piece model block data fast inheritance method, which can be realized by electronic equipment, wherein the electronic equipment can be a terminal or a server. As shown in FIG. 1, a flow chart of a multithreading-based fast inheritance method for three-dimensional rolled piece model block data, a processing flow of the method may include the following steps:
s101: preprocessing an original rolled piece model by adopting a model partitioning method;
s102: obtaining a preprocessed rolled piece model, and carrying out grid reconstruction on the rolled piece model to obtain a new rolled piece model which has the same length and section shape as the original rolled piece model and is different from grids;
s103: dividing an original rolled piece model into a plurality of blocks along the length direction, and setting a search radius R according to the length of each block;
s104: judging the search radius R and the position from the target node to the block edge, and determining a search position; presetting a data output condition, and outputting node numbers and node data meeting the condition;
s105: and traversing and calculating each node or unit in the new rolled piece model, obtaining the data distribution of the new rolled piece model after the multithreading calculation is finished, and finishing the multithreading-based fast inheritance of the data of the three-dimensional rolled piece model blocks.
Optionally, step S101 further includes: and by setting multi-thread parallel execution, the new rolled piece model is processed in blocks.
Optionally, in step S103, dividing the original rolled piece model into a plurality of blocks along the length direction, and setting a search radius R according to the length of each block, including:
dividing the number of blocks of the original rolled piece model according to the length of the rolled piece and the size of the grid; and the length of each part is a calculated value according to the length of the rolled piece and the set divided parts, and the preset size of the search radius R is carried out according to the divided length.
Optionally, step S104 further includes: and the target unit is a unit formed by a plurality of target nodes.
Optionally, in step S104, the search radius and the position from the target node to the block edge are determined, and the search position is determined; presetting a data output condition, outputting a node number and node data meeting the condition, and comprising:
s141: determining that the search range is a whole ball by judging the block position of the search ball of the target node or the target unit corresponding to the original rolled piece model;
s142: judging the distance d from the target node to the left edge of the block 1 The size of (d); judging the distance d from the target node to the right edge of the block 2 According to the search radius R and the distance d 1 And a distance d 2 Determining a search position;
s143: and presetting a data output condition, calculating by using an inverse distance weighted average formula, and outputting the node number and the node data meeting the condition.
Optionally, in step S142, the distance d is determined according to the search radius R 1 And a distance d 2 Determining a search location, comprising:
if R is less than or equal to d 1 And R is not more than d 2 If the search range is limited to the target node or the block corresponding to the target unit; if R is>d 1 Or R>d 2 Then the target node or the neighboring partition of the partition where the target unit is located needs to be searched at the same time.
Optionally, in step S143, presetting a data output condition, calculating by using an inverse distance weighted average formula, and outputting a node number and node data that satisfy the condition, including:
the self-distance D in the searched sub-block corresponding to the target node i Node number N smaller than search radius R i And node data are output, wherein D i >0; and calculating by using an inverse distance weighted average formula, wherein the calculation result is the data of the target node or the target unit.
The embodiment of the invention provides a method for quickly inheriting the data information of temperature, stress, strain and the like of a mesh model with distortion after rolling into a re-planned mesh model. And successively inheriting and transmitting the model data according to the steps of grid model reconstruction, model blocking and multithreading node data searching and calculating. Model partitioning can shorten search time by reducing the scope of searching nodes; the use of multiple threads puts tasks occupying a long time in a program into a background for processing, so that a user interface can respond to user operation more quickly, the calculation efficiency can be greatly improved, and the calculation time is reduced.
The embodiment of the invention provides a multithreading-based three-dimensional rolled piece model block data fast inheritance method, which can be realized by electronic equipment, wherein the electronic equipment can be a terminal or a server. As shown in fig. 2, a flow chart of a multithreading-based fast inheritance method for three-dimensional rolled piece model block data, a processing flow of the method may include the following steps:
s201: preprocessing an original rolled piece model by adopting a model partitioning method;
in one possible implementation, the original rolled piece model is processed in blocks by setting multiple threads to execute in parallel.
In the embodiment of the invention, A. Because the data volume of the rolling process model is huge, and the number of nodes and units is often over 106 orders of magnitude, directly carrying out corresponding operation on the model seriously wastes time resources due to overlarge calculated amount; therefore, the invention adopts the model blocking method to preprocess the rolled piece, and the model blocking method can not only save time by reducing the range of searching nodes and units, but also set multithreading concurrent execution, thereby greatly improving the operation efficiency.
S202: and obtaining a preprocessed rolled piece model, and carrying out grid reconstruction on the rolled piece model to obtain a new rolled piece model which has the same length and section shape as the original rolled piece model and has a different grid.
In a feasible implementation mode, a rolled piece model with grid distortion after the previous calculation is finished is extracted, and grid reconstruction is carried out on the model to obtain a new rolled piece model which is the same as the original model in length and section shape and has different grids.
S203: and dividing the original rolled piece model into a plurality of blocks along the length direction, and setting a search radius R according to the length of each block.
In a possible embodiment, the original product model is divided into several portions along its length, the number of portions being dependent on the product length and the grid size, the length of each portion being adapted, and the search radius being set on the basis thereof, the search radius being not greater than the length of each portion.
S204: determining that the search range is a whole ball by judging the block position of the search ball of the target node or the target unit corresponding to the original rolled piece model;
s205: judging the distance d from the target node to the left edge of the block 1 The size of (d); judging the distance d from the target node to the right edge of the block 2 According to the search radius R and the distance d 1 And a distance d 2 A search location is determined.
In one possible embodiment, the search radius R and the distance d from the target node or target unit to the two side edges of the block are determined 1 、d 2 Determining a search location, comprising:
if R is less than or equal to d 1 And R is not more than d 2 If the search range is limited to the target node or the block corresponding to the target unit; if R is>d 1 Or R>d 2 Then the target node or the neighboring partition of the block where the target unit is located needs to be searched at the same time.
In a possible implementation manner, in order to ensure that the search range is a whole sphere, it is necessary to determine the position of the search sphere of the target node or target unit corresponding to the original modelAt the block location; as shown in FIG. 3, for example, if a target node or target unit appears in Block 2, the distance d from the target node or target unit to the left boundary should be determined first 1 And a distance d to the right boundary 2 Whether it is smaller than the search radius R; if R is less than or equal to d 1 And R is less than or equal to d 2 If so, the search range is limited to the block 2, and other blocks do not need to be searched; if R is>d 1 If the search range is the block 1 and the block 2; in the same way, if R>d 2 The search range is then block 2 and block 3.
S206: and presetting a data output condition, calculating by using an inverse distance weighted average formula, and outputting the node number and the node data meeting the condition.
In one possible embodiment, presetting a data output condition, calculating by using an inverse distance weighted average formula, and outputting a node number and node data that satisfy the condition includes:
corresponding the target node to the self-to-self distance D in the block to be searched i (D i >0) And outputting the node number Ni and the node data which are smaller than the search radius R, and calculating by using an inverse distance weighted average formula, wherein the calculation result is the target node or unit data.
In a possible embodiment, the inheritance calculation of the new model data takes the temperature data T as an example, and the target node corresponds to the self-distance D in the block to be searched i (D i >0) Node number N smaller than search radius R i And node temperature T i And outputting, if k (k is more than or equal to 1) nodes are searched in the corresponding block, calculating according to the following formula (1) of inverse distance weighted average formula:
if no node is searched or D is searched in the corresponding block i Node of 0, then T N The temperature of the nearest node to the temperature sensor is obtained; the other data information is calculated in the same way.
S207: traversing and calculating each node in the new rolled piece model, obtaining the data distribution of the new rolled piece model after multi-thread calculation is completed, and completing the fast inheritance of the multi-thread-based three-dimensional rolled piece model block data.
In one possible embodiment, each node or element in the new rolled piece model is calculated in a traversal mode and applied to each node or element in the new model; in the process, the new rolled piece model is divided into blocks according to thread number, the rolled piece models of different blocks are set into different threads, and tasks occupying long time in the program are put into a background for processing by using multiple threads, so that a user interface can respond to user operation more quickly, and the calculation efficiency can be greatly improved; and obtaining the data distribution of the new model after the calculation is finished.
In the embodiment of the present invention, as shown in fig. 4-5, fig. 4 is a mesh temperature model with distortion, and fig. 5 is a mesh temperature model after mesh reconstruction and data inheritance; it can be seen that the temperature distribution of the section of the rolled piece obtained by the block inverse distance weighted average calculation can better reflect the temperature distribution of the original model. Through block search and multithreading, the inheritance efficiency is greatly improved, and the required time is obviously reduced compared with the time directly using an inverse distance weighted average method. And (4) continuing to perform subsequent numerical simulation calculation by using the rolled piece model inheriting the data, so that a good simulation result can be obtained.
The embodiment of the invention provides a method for quickly inheriting the data information of temperature, stress, strain and the like of a mesh model with distortion after rolling into a re-planned mesh model. And successively inheriting and transmitting model data according to the steps of grid model reconstruction, model blocking and multithreading node data searching and calculating. Model partitioning can shorten search time by reducing the scope of searching nodes; the use of multiple threads puts tasks occupying a long time in a program into a background for processing, so that a user interface can respond to user operation more quickly, the calculation efficiency can be greatly improved, and the calculation time is reduced.
FIG. 6 is a block diagram illustrating a multi-threaded based three-dimensional workpiece model block data fast inheritance system in accordance with an exemplary embodiment. Referring to fig. 6, the system 300 includes:
the model preprocessing module 310 is used for preprocessing the original rolled piece model by adopting a model partitioning method;
the grid reconstruction module 320 is used for obtaining a preprocessed rolled piece model and carrying out grid reconstruction on the rolled piece model to obtain a new rolled piece model which has the same length and section shape as the original rolled piece model and is different in grid;
a search determination module 330, configured to divide the original rolled piece model into a plurality of portions along the length direction thereof, and set a search radius according to the length of each portion;
the data output module 340 is configured to determine a search radius and a position from a target node to a block, and determine a search position; presetting a data output condition, and outputting a node number and node data which meet the condition;
and the traversing module 350 is used for traversing and calculating each node or unit in the new rolled piece model, obtaining the data distribution of the new rolled piece model after the multithreading calculation is finished, and finishing the fast inheritance of the block data of the three-dimensional rolled piece model based on the multithreading.
Optionally, the model preprocessing module 310 is configured to perform block processing on the original rolled piece model by setting multiple threads to execute in parallel.
Optionally, the searching and determining module 330 is configured to divide the original rolled piece model into the number of copies according to the length of the rolled piece and the size of the grid; the length of each part is a calculated value according to the length of a rolled piece and a set divided part, and the size of the search radius is a preset value; optionally, the data output module 340 is configured to determine that the search range is a whole sphere by determining a block position where the search sphere of the target node or the target unit corresponds to the original model.
Optionally, the data output module 340 is configured to determine that the search range is a whole sphere by determining a block position where the search sphere of the target node or the target unit corresponds to the original model;
judging the search radius R and the distances d1 and d2 from the target node or the target unit to the edges of the two sides of the block, and determining the search position;
and presetting a data output condition, calculating by using an inverse distance weighted average formula, and outputting the node number and the node data meeting the condition.
Optionally, the data output module 340 is configured to, if R is less than or equal to d1 and R is less than or equal to d2, limit the search range to the target node or the partition corresponding to the target unit; if R > d1 or R > d2, then the target node or the neighboring block of the block where the target unit is located needs to be searched at the same time.
Optionally, the data output module 340 is configured to output a node number Ni and node data, where a distance Di (Di > 0) from the target node to the target node within the block to be searched is smaller than the search radius R, and calculate by using an inverse distance weighted average formula, where a calculation result is the target node or unit data.
Through the method, the method can be used for quickly inheriting the data information such as temperature, stress, strain and the like of the grid model with the distortion after rolling into the re-planned grid model. And successively inheriting and transmitting the model data according to the steps of grid model reconstruction, model blocking and multithreading node data searching and calculating. Model partitioning can shorten search time by reducing the scope of searching nodes; the use of multiple threads puts tasks occupying a long time in a program into a background for processing, so that a user interface can respond to user operation more quickly, the calculation efficiency can be greatly improved, and the calculation time is reduced.
Fig. 7 is a schematic structural diagram of an electronic device 400 according to an embodiment of the present invention, where the electronic device 400 may generate relatively large differences due to different configurations or performances, and may include one or more processors (CPUs) 401 and one or more memories 402, where the memory 402 stores at least one instruction, and the at least one instruction is loaded and executed by the processor 401 to implement the following steps of fast inheriting a data block of a multi-thread-based three-dimensional rolled piece model:
s1: preprocessing an original rolled piece model by adopting a model partitioning method;
s2: obtaining a preprocessed rolled piece model, and carrying out grid reconstruction on the rolled piece model to obtain a new rolled piece model which has the same length and section shape as the original rolled piece model and has different grids;
s3: dividing an original rolled piece model into a plurality of parts along the length direction of the original rolled piece model, and setting a search radius according to the length of each part;
s4: judging the search radius and the position from the target node to the block, and determining the search position; presetting a data output condition, and outputting node numbers and node data meeting the condition;
s5: and traversing and calculating each node or unit in the new rolled piece model, and completing multithread calculation.
In an exemplary embodiment, a computer-readable storage medium, such as a memory, is also provided that includes instructions executable by a processor in a terminal to perform the above-described multithreading-based three-dimensional workpiece model block data fast inheritance method. For example, the computer readable storage medium may be a ROM, a Random Access Memory (RAM), a CD-ROM, a magnetic tape, a floppy disk, an optical data storage device, and the like.
It will be understood by those skilled in the art that all or part of the steps for implementing the above embodiments may be implemented by hardware, or may be implemented by a program instructing relevant hardware, where the program may be stored in a computer-readable storage medium, and the above-mentioned storage medium may be a read-only memory, a magnetic disk or an optical disk, etc.
The above description is only for the purpose of illustrating the preferred embodiments of the present invention and should not be taken as limiting the scope of the present invention, which is intended to cover any modifications, equivalents, improvements, etc. within the spirit and scope of the present invention.
Claims (4)
1. A multithreading-based three-dimensional rolled piece model block data fast inheritance method is characterized by comprising the following steps:
s1: preprocessing an original rolled piece model by adopting a model partitioning method;
s2: obtaining a preprocessed rolled piece model, and carrying out grid reconstruction on the rolled piece model to obtain a new rolled piece model which has the same length and section shape as the original rolled piece model and has different grids;
the step S2 further includes: by setting multi-thread parallel execution, the new rolled piece model is processed in blocks;
s3: dividing an original rolled piece model into a plurality of blocks along the length direction, and setting a search radius R according to the length of each block;
in step S3, dividing the original rolled piece model into a plurality of blocks along the length direction, and setting a search radius R according to the length of each block, including:
dividing the number of blocks of the original rolled piece model according to the length of the rolled piece and the size of the grid; the length of each block is a calculated value according to the length of a rolled piece and the set division number, and the preset size of the search radius R is carried out according to the division length;
s4: judging the search radius R and the position from the target node to the block edge, and determining a search position; presetting a data output condition, and outputting node numbers and node data meeting the condition;
in step S4, the method further includes: the target unit is a unit formed by a plurality of target nodes;
in the step S4, the search radius and the position from the target node to the block edge are judged, and the search position is determined; presetting a data output condition, outputting a node number and node data meeting the condition, and comprising:
s41: determining that the search range is a whole ball by judging the block position of the search ball of the target node or the target unit corresponding to the original rolled piece model;
s42: judging the distance d from the target node to the left edge of the block 1 The size of (d); judging the distance d from the target node to the right edge of the block 2 According to the search radius R and the distance d 1 And a distance d 2 Determining a search position;
s43: presetting a data output condition, calculating by using an inverse distance weighted average formula, and outputting node numbers and node data which meet the condition;
s5: and traversing and calculating each node in the new rolled piece model, obtaining the data distribution of the new rolled piece model after the multithreading calculation is finished, and finishing the fast inheritance of the block data of the multithreading-based three-dimensional rolled piece model.
2. The method according to claim 1, wherein in step S42, the distance d is determined according to the search radius R 1 And a distance d 2 Determining a search location, comprising:
if R is less than or equal to d 1 And R is not more than d 2 If the search range is limited to the target node or the block corresponding to the target unit; if R is>d 1 Or R>d 2 Then a search needs to be performed at the target node or at a block adjacent to the block where the target unit is located.
3. The method according to claim 1, wherein in step S43, presetting a data output condition, calculating by using an inverse distance weighted average formula, and outputting the node number and the node data satisfying the condition comprises:
the self-distance D in the searched sub-block corresponding to the target node i Node number N smaller than search radius R i And node data are output, wherein D i >0; and calculating by using an inverse distance weighted average formula, wherein the calculation result is the data of the target node or the target unit.
4. A multithreading-based three-dimensional rolled piece model block data fast inheritance system is characterized by comprising:
the model preprocessing module is used for preprocessing an original rolled piece model by adopting a model partitioning method;
the grid reconstruction module is used for obtaining a preprocessed rolled piece model and carrying out grid reconstruction on the rolled piece model to obtain a new rolled piece model which has the same length and section shape as the original rolled piece model and is different in grid;
by setting multi-thread parallel execution, the new rolled piece model is processed in blocks;
the searching radius determining module is used for dividing the original rolled piece model into a plurality of blocks along the length direction and setting a searching radius R according to the length of each block;
the searching radius determining module is used for dividing the original rolled piece model into parts according to the length of the rolled piece and the size of the grid; the length of each part is a calculated value according to the length of a rolled piece and the set divided parts, and the size of the search radius is a preset value; the data output module 340 is configured to determine that a search range is a whole sphere by determining a block position where a search sphere of a target node or a target unit corresponds to an original model;
the calculation module is used for judging the search radius R and the position from the target node to the block edge to determine a search position; presetting a data output condition, and outputting node numbers and node data meeting the condition;
the calculation module is used for determining that the search range is a whole sphere by judging the block position of the search sphere of the target node or the target unit corresponding to the original model;
judging the search radius R and the distances d1 and d2 from the target node or the target unit to the edges of the two sides of the block, and determining the search position;
presetting a data output condition, calculating by using an inverse distance weighted average formula, and outputting node numbers and node data which meet the condition;
and the traversing module is used for traversing and calculating each node in the new rolled piece model, obtaining the data distribution of the new rolled piece model after the multithreading calculation is finished, and finishing the fast inheritance of the data of the multithreading-based three-dimensional rolled piece model block.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202211365563.1A CN115470598B (en) | 2022-11-03 | 2022-11-03 | Multithreading-based three-dimensional rolled piece model block data rapid inheritance method and system |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202211365563.1A CN115470598B (en) | 2022-11-03 | 2022-11-03 | Multithreading-based three-dimensional rolled piece model block data rapid inheritance method and system |
Publications (2)
Publication Number | Publication Date |
---|---|
CN115470598A CN115470598A (en) | 2022-12-13 |
CN115470598B true CN115470598B (en) | 2023-03-24 |
Family
ID=84338183
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN202211365563.1A Active CN115470598B (en) | 2022-11-03 | 2022-11-03 | Multithreading-based three-dimensional rolled piece model block data rapid inheritance method and system |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN115470598B (en) |
Family Cites Families (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN103106313B (en) * | 2013-03-08 | 2015-09-30 | 攀钢集团攀枝花钢钒有限公司 | Roll consequent order reconstructing method |
CN104820729B (en) * | 2015-03-13 | 2018-05-25 | 攀钢集团攀枝花钢钒有限公司 | The temperature inheritance method of the full rolling process simulation analysis of rail |
ITUA20163745A1 (en) * | 2016-05-24 | 2017-11-24 | Nuovo Pignone Tecnologie Srl | METHOD AND SYSTEM FOR MONITORING THE HEALTH STATUS OF A ROLLING BEARING OF A MACHINE, AND MACHINE EQUIPPED WITH THIS SYSTEM |
CN115238559B (en) * | 2022-09-21 | 2022-12-02 | 北京科技大学 | Method and system for automatically extracting boundary components in three-dimensional rolled piece stretching modeling process |
-
2022
- 2022-11-03 CN CN202211365563.1A patent/CN115470598B/en active Active
Also Published As
Publication number | Publication date |
---|---|
CN115470598A (en) | 2022-12-13 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN111126668B (en) | Spark operation time prediction method and device based on graph convolution network | |
CN111783867A (en) | Machine learning algorithm selection method and device | |
JP2011118743A (en) | Vector computer and instruction control method therefor | |
CN110717687A (en) | Evaluation index acquisition method and system | |
CN113553175B (en) | Optimal sorting algorithm selection method for traffic data flow | |
CN105468439A (en) | Adaptive parallel algorithm for traversing neighbors in fixed radius under CPU-GPU (Central Processing Unit-Graphic Processing Unit) heterogeneous framework | |
CN114936085A (en) | ETL scheduling method and device based on deep learning algorithm | |
CN114168318A (en) | Training method of storage release model, storage release method and equipment | |
CN112001491A (en) | Search method and device for determining neural network architecture for processor | |
CN115481549A (en) | Cylindrical linear motor multi-objective optimization method, equipment and storage medium | |
DE102015015182A1 (en) | Systems, devices, and methods for k-nearest neighbor search | |
CN111400521B (en) | Graph data processing method, device, equipment and medium | |
CN111832693B (en) | Neural network layer operation and model training method, device and equipment | |
CN115470598B (en) | Multithreading-based three-dimensional rolled piece model block data rapid inheritance method and system | |
WO2019141160A1 (en) | Data processing method and apparatus | |
CN113537614A (en) | Construction method, system, equipment and medium of power grid engineering cost prediction model | |
Tang et al. | Optimizing and auto-tuning iterative stencil loops for GPUs with the in-plane method | |
CN107992821B (en) | Image identification method and system | |
CN117519946A (en) | Memory resource scheduling method, device, equipment and medium in deep learning network | |
CN116069603B (en) | Performance test method of application, method and device for establishing performance test model | |
CN112015472B (en) | Sparse convolutional neural network acceleration method and system based on data flow architecture | |
CN118502964B (en) | Tokamak new classical circumferential viscous torque CUDA simulation implementation method | |
CN117407793B (en) | Parallelization strategy optimization method, system, equipment and medium for large language model | |
CN113362901B (en) | Method and system for rapidly comparing whole genome annotation intervals | |
CN118113425A (en) | Adaptive prediction method and device for parallel discrete event simulation thread pool |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
GR01 | Patent grant | ||
GR01 | Patent grant |