CN117113732B - Latin hypercube design method suitable for non-hypercube constraint space - Google Patents

Latin hypercube design method suitable for non-hypercube constraint space Download PDF

Info

Publication number
CN117113732B
CN117113732B CN202311378703.3A CN202311378703A CN117113732B CN 117113732 B CN117113732 B CN 117113732B CN 202311378703 A CN202311378703 A CN 202311378703A CN 117113732 B CN117113732 B CN 117113732B
Authority
CN
China
Prior art keywords
test design
points
design point
preset
constraint
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN202311378703.3A
Other languages
Chinese (zh)
Other versions
CN117113732A (en
Inventor
马一鸣
贺儒飞
彭煜民
李泽泉
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Peak and Frequency Regulation Power Generation Co of China Southern Power Grid Co Ltd
Original Assignee
Peak and Frequency Regulation Power Generation Co of China Southern Power Grid Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Peak and Frequency Regulation Power Generation Co of China Southern Power Grid Co Ltd filed Critical Peak and Frequency Regulation Power Generation Co of China Southern Power Grid Co Ltd
Priority to CN202311378703.3A priority Critical patent/CN117113732B/en
Publication of CN117113732A publication Critical patent/CN117113732A/en
Application granted granted Critical
Publication of CN117113732B publication Critical patent/CN117113732B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F30/00Computer-aided design [CAD]
    • G06F30/20Design optimisation, verification or simulation
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F18/00Pattern recognition
    • G06F18/20Analysing
    • G06F18/23Clustering techniques
    • G06F18/232Non-hierarchical techniques
    • G06F18/2321Non-hierarchical techniques using statistics or function optimisation, e.g. modelling of probability density functions
    • G06F18/23213Non-hierarchical techniques using statistics or function optimisation, e.g. modelling of probability density functions with fixed number of clusters, e.g. K-means clustering
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F2111/00Details relating to CAD techniques
    • G06F2111/04Constraint-based CAD
    • YGENERAL 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
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02EREDUCTION OF GREENHOUSE GAS [GHG] EMISSIONS, RELATED TO ENERGY GENERATION, TRANSMISSION OR DISTRIBUTION
    • Y02E60/00Enabling technologies; Technologies with a potential or indirect contribution to GHG emissions mitigation

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • Data Mining & Analysis (AREA)
  • Evolutionary Computation (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Probability & Statistics with Applications (AREA)
  • Geometry (AREA)
  • Computer Hardware Design (AREA)
  • Life Sciences & Earth Sciences (AREA)
  • Artificial Intelligence (AREA)
  • Bioinformatics & Cheminformatics (AREA)
  • Bioinformatics & Computational Biology (AREA)
  • Computer Vision & Pattern Recognition (AREA)
  • Evolutionary Biology (AREA)
  • Management, Administration, Business Operations System, And Electronic Commerce (AREA)
  • Design And Manufacture Of Integrated Circuits (AREA)

Abstract

The application relates to a Latin hypercube design method suitable for a non-hypercube constraint space. The method comprises the following steps: screening constraint test design points from the initial test design point set according to preset constraint conditions; generating a row number combination according to a preset number of dimensions; determining a newly added test design point for the array number combination; under the condition that the array combination meets the array number combination requirement, clustering the newly added test design points according to a clustering algorithm to obtain a clustering center point; and determining the distance between the clustering center point and the constraint test design point, and generating a target test design point set according to the distance and the clustering center point. By adopting the method, under the condition of considering complex constraint relations among variables in each dimension, design points which can fully represent data characteristics in the design space can be selected in the non-hypercube space, so that the spatial uniformity and orthogonality of the design points in the non-hypercube constraint space are ensured, and the acquisition efficiency of the design points is further improved.

Description

Latin hypercube design method suitable for non-hypercube constraint space
Technical Field
The present application relates to the field of experimental design technology, and in particular, to a latin hypercube design method, apparatus, computer device, storage medium, and computer program product applicable to non-hypercube constrained spaces.
Background
Experimental design techniques fully characterize the data distribution characteristics within the global design space by selecting more "typical" design points within the design space. Compared with the conventional gridding analysis, the experimental design technology has the advantages that: firstly, through reasonable design, blindness of selecting design points in a design space is avoided, and the efficiency of a sampling process is improved; secondly, through the experimental design method, the data characteristics in the whole design space can be accurately represented by a small number of design points.
Traditional test design methods include full/partial factor design, box-Behnken design, center composite design, and the like.
However, most of test design points are arranged in the boundary area of the design space in the conventional technology, data information in the middle area of the design space is difficult to obtain, and consideration of complex constraint relations among dimensional variables is absent, so that the number of test design points meeting constraint conditions is reduced compared with that of test design points given in a sampling process, data characteristics in the design space cannot be fully represented, and the acquisition efficiency of the test design points is not improved.
Disclosure of Invention
In view of the foregoing, it is desirable to provide a latin hypercube design method, apparatus, computer device, computer readable storage medium, and computer program product for non-hypercube constraint space that can improve the efficiency of acquisition of test design points.
In a first aspect, the present application provides a latin hypercube design method suitable for use with non-hypercube constrained spaces, the method comprising:
screening constraint test design points from the initial test design point set according to preset constraint conditions; the initial test design point set comprises initial test design points distributed on a preset number of dimensions; the constraint test design points are the initial test design points meeting the preset constraint conditions;
generating a row number combination according to the preset number of dimensions;
determining a new test design point for the array number combination;
under the condition that the array combination meets the preset array combination requirement, clustering the newly-added test design points according to a preset clustering algorithm to obtain clustering center points;
distance data between the clustering center points and the constraint test design points are determined, and a target test design point set is generated according to the distance data and the clustering center points.
In one embodiment, before the constraint test design points are screened from the initial test design point set according to the preset constraint condition, the method further includes:
generating a random test design point set according to the initial test design points and the preset number of dimensions;
obtaining row vectors corresponding to the random test design point set, and carrying out local search on the row vectors according to a preset local search mode to obtain a first intermediate test design point set;
according to a preset disturbance strategy, the first intermediate test design point set is disturbed to obtain a second intermediate test design point set;
according to the preset local searching mode, carrying out local searching on the second intermediate test design point set to obtain a third intermediate test design point set;
and taking the third intermediate test design point set as the initial test design point set under the condition that the third intermediate test design point set meets a preset termination condition.
In one embodiment, the generating the permutation number combination according to the preset number of dimensions includes:
combining the preset number of dimensions according to a preset combination mode to obtain a dimension combination; the combination of dimensions includes at least two dimensions;
And generating the arrangement number combination according to the dimension combination.
In one embodiment, the determining the new trial design points for the set of permutation numbers includes:
obtaining distance difference data of the constraint test design point in a first target dimension; the first target dimension is a first dimension corresponding to a target dimension combination in the permutation number set; the distance difference data represents the distance between any two constraint test design points;
screening a distance difference maximum value from the distance difference data, and acquiring a target constraint test design point corresponding to the distance difference maximum value;
and acquiring the position data of the target constraint test design point on the first target dimension, and determining the position data corresponding to the newly-added test design point aiming at the first target dimension according to the position data.
In one embodiment, after determining the position data corresponding to the new design point for the first target dimension, the method further includes:
acquiring a search step length and a search range aiming at a second target dimension; the second target dimension is the dimension after the first target dimension in the target dimension combination;
According to a preset searching mode, determining candidate position data of a newly added experimental design point aiming at the second target dimension in the searching range;
and taking the candidate position data meeting the requirement of the preset newly-added test design point as the position data of the newly-added test design point aiming at the second target dimension.
In one embodiment, the generating the target test design point set according to the distance data and the clustering center point includes:
generating the target test design point set according to the clustering center points and the constraint test design points under the condition that the distance data is larger than or equal to a preset distance threshold value;
and screening out a replacement test design point from the newly-increased test design points corresponding to the clustering center point under the condition that the distance data is smaller than the preset distance threshold value, and generating the target test design point set according to the replacement test design point and the constraint test design point.
In one embodiment, clustering the newly added test design points according to a preset clustering algorithm to obtain a clustering center point includes:
screening a center point from the newly added test design points;
Classifying the newly added test design points according to the distance data between the newly added test design points and the center point to obtain test design point groups;
determining grouping center points corresponding to the grouping of the test design points, and taking the grouping center points as clustering center points of the grouping of the test design points corresponding to the grouping center points under the condition that the position information of the grouping center points meets the preset clustering requirement.
In a second aspect, the present application also provides a latin hypercube design apparatus adapted for use with non-hypercube constrained spaces, said apparatus comprising:
the test design point screening module is used for screening constraint test design points from the initial test design point set according to preset constraint conditions; the initial test design point set comprises initial test design points distributed on a preset number of dimensions; the constraint test design points are the initial test design points meeting the preset constraint conditions;
the combination generating module is used for generating a row number combination according to the preset number of dimensions;
the test design point adding module is used for determining the new test design points aiming at the arrangement number combination;
The test design point clustering module is used for clustering the newly-added test design points according to a preset clustering algorithm under the condition that the array combination meets the preset array combination requirement to obtain a clustering center point;
and the set determining module is used for determining distance data between the clustering center points and the constraint test design points and generating a target test design point set according to the distance data and the clustering center points.
In a third aspect, the present application also provides a computer device. The computer device comprises a memory and a processor, the memory storing a computer program which, when executed by the processor, implements the steps of the method described above.
In a fourth aspect, the present application also provides a computer-readable storage medium. The computer readable storage medium has stored thereon a computer program which, when executed by a processor, implements the steps of the method described above.
In a fifth aspect, the present application also provides a computer program product. The computer program product comprising a computer program which, when executed by a processor, implements the steps of the method described above.
According to the Latin hypercube design method, the Latin hypercube design device, the computer equipment, the storage medium and the computer program product applicable to the non-hypercube constraint space, constraint test design points are screened out from the initial test design point set according to preset constraint conditions, so that initial test design points meeting preset constraint conditions are screened out from the initial test design point set containing the initial test design points distributed in a preset number of dimensions to serve as constraint test design points, and preliminary determination of the test design points is realized; generating a permutation number combination according to a preset number of dimensions, so as to determine a permutation number set and a permutation combination according to preset dimension combination requirements; determining newly added test design points for the array number combination, so as to determine the positions of the newly added test design points for each dimension in the array number combination according to a preset arrangement mode; under the condition that the array combination meets the preset array combination requirement, clustering the newly-added test design points according to a preset clustering algorithm to obtain clustering center points, so as to cluster the newly-added test design points and determine the clustering center corresponding to the newly-added test design points; determining distance data between a clustering center point and constraint test design points, generating a target test design point set according to the distance data and the clustering center point, selecting a clustering center or other test design points to add the constraint test design points based on the distance between the clustering center and the original test design points, further determining the target test design point set, screening out the constraint test design points meeting requirements from the initial test design points, combining a preset number of dimensions, determining array combination formed by a plurality of dimensional combinations, determining the corresponding positions of the newly-added test design points in each dimension in the array combination according to a preset test design point newly-adding mode, selecting the clustering center or other test design points to add the constraint test design points based on the distance between the clustering center obtained by clustering the newly-added test design points and the constraint test design points under the condition that the array combination meets preset requirements, further determining the target test design point set, selecting the test design points capable of fully representing data characteristics in the non-super-cube space under the condition of considering complex constraint relation among variables in each dimension, and guaranteeing uniformity of the test design points in the non-super-cube space, and further improving the efficiency of the test design.
Drawings
FIG. 1 is a diagram of an application environment for a Latin hypercube design method suitable for use in non-hypercube constrained spaces, in one embodiment;
FIG. 2 is a flow diagram of a Latin hypercube design method suitable for use in non-hypercube constrained spaces in one embodiment;
FIG. 3 is a flow diagram of another Latin hypercube design method suitable for use in non-hypercube constrained spaces in one embodiment;
FIG. 4 is a schematic diagram of a trial design point distribution and constraint space boundaries in one embodiment;
FIG. 5 is a schematic diagram of a distribution of additional design points in one embodiment;
FIG. 6 is a schematic diagram of a distribution of additional design points of an embodiment;
FIG. 7 is a schematic diagram of a distribution of cluster centers in one embodiment;
FIG. 8 is a schematic diagram of a distribution of two-dimensional design of experiments points in one embodiment;
FIG. 9 is a schematic diagram of a distribution of points of another two-dimensional test design in one embodiment;
FIG. 10 is a block diagram of a Latin hypercube design apparatus suitable for use in non-hypercube constrained spaces in one embodiment;
FIG. 11 is an internal block diagram of a computer device in one embodiment.
Detailed Description
In order to make the objects, technical solutions and advantages of the present application more apparent, the present application will be further described in detail with reference to the accompanying drawings and examples. It should be understood that the specific embodiments described herein are for purposes of illustration only and are not intended to limit the present application.
The Latin hypercube design method suitable for the non-hypercube constraint space can be applied to an application environment shown in figure 1. Wherein the terminal 102 communicates with the server 104 via a network. The data storage system may store data that the server 104 needs to process. The data storage system may be integrated on the server 104 or may be located on a cloud or other network server. The server 104 screens constraint test design points from the initial test design point set according to preset constraint conditions; the initial test design point set comprises initial test design points distributed on a preset number of dimensions; the constraint test design points are initial test design points meeting preset constraint conditions; the server 104 generates an arrangement number set according to a preset number of dimensions and constraint test design points; the server 104 determines a new test design point for the array number set, and generates an array number combination according to the new test design point and the constraint test design point; under the condition that the array combination meets the preset array combination requirement, the server 104 clusters the newly-added test design points according to a preset clustering algorithm to obtain a clustering center point; the server 104 determines distance data between the cluster center points and the constraint trial design points, and generates a target trial design point set according to the distance data and the cluster center points. The terminal 102 may be, but is not limited to, various personal computers, notebook computers, smart phones, tablet computers, internet of things devices, and portable wearable devices. The server 104 may be implemented as a stand-alone server or as a server cluster of multiple servers.
In some embodiments, as shown in fig. 2, a latin hypercube design method applicable to non-hypercube constraint spaces is provided, and this embodiment is illustrated with the method applied to a terminal, it being understood that the method may also be applied to a server, and may also be applied to a system including a terminal and a server, and implemented through interaction of the terminal and the server. In this embodiment, the method includes the steps of:
step S202, constraint test design points are screened from the initial test design point set according to preset constraint conditions.
The preset constraint condition may be data for judging whether the initial test design point in the initial test design point set meets the requirement of the preset test design point.
The initial test design point set may refer to a set formed by a plurality of initial test design points, in practical application, the initial test design point set may include a plurality of initial test design points distributed on a preset number of dimensions, and the initial test design points may refer to points corresponding to data for characterizing data distribution features in a global design space in a test design process.
The constraint test design point may be an initial test design point satisfying a preset constraint condition.
As an example, aiming at the problem of selecting test design points in a certain non-hypercube constraint space, a terminal acquires a pre-built initial test design point set, checks each initial test design point in the initial test design point set one by one according to a preset constraint condition, and takes the initial test design point meeting the preset constraint condition as a constraint test design point.
Step S204, generating a row number combination according to the preset number of dimensions.
The preset number of dimensions may refer to dimensions corresponding to test design points in the initial test design point set, and in practical application, the initial test design points in the initial test design point set have two dimensions, and then the initial test design points include two dimensions.
As an example, the initial test design point set includes k dimensions, for a first dimension p in a first preset dimension combination a, in order to meet the projection characteristic of the latin hypercube design (Latin Hypercube Design, LHD), the terminal performs small-to-large arrangement on constraint test design points (dimensional position data or dimensional values in the dimension p) according to the dimension p, so as to obtain test design point arrangement in the dimension p, and so on, the terminal performs test design point arrangement for each dimension in each preset dimension combination, so as to obtain test design point arrangement in each dimension combination, and the terminal uses a set formed by the test design point arrangement in each dimension combination as an arrangement number set.
Step S206, determining new test design points for the combination of the arrangement number.
The newly added test design points may be test design points that need to be set separately for the combination of the number of rows based on constraint test design points.
The permutation and combination may be a combination obtained by combining a preset number of dimensions according to a specific combination mode.
As an example, a terminal determines positions corresponding to newly-added test design points for an arrangement number set according to distances between constraint test design points, and for a first dimension p in a first preset dimension combination a, the terminal obtains a distance between each constraint test design point in the dimension p, a distance between a test design point with a minimum dimension value in the dimension p and a boundary 0, and a distance between a test design point with a maximum dimension value in the dimension p and a boundary 1, so as to obtain a distance set D, the terminal screens out two constraint test design points corresponding to a maximum distance value in the distance set D, the terminal uses a middle position between the two constraint test design points as a position of the first newly-added test design point in the dimension p, updates the distance set D, and repeats the operation, thereby determining positions of all newly-added test design points in the dimension p, and searching an optimal position in the dimension q direction according to the position of the first newly-added test design point in the dimension p, thereby determining the position of the first newly-added test design point in the dimension q, repeating the position of the test design point in the dimension p, and determining positions of all newly-added test design points in the dimension p.
Step S208, clustering the newly added test design points according to a preset clustering algorithm under the condition that the array combination meets the preset array combination requirement, so as to obtain a clustering center point.
The preset permutation and combination requirement may be data for determining whether the permutation and combination meets the preset requirement, and in practical application, the preset permutation and combination requirement may include data for determining whether the permutation and combination is calculated.
The preset clustering algorithm may refer to an algorithm for classifying the data, and in practical application, the preset clustering algorithm may include a K-Means algorithm.
The clustering center point may be a center point of the test design point obtained after the new test design point is clustered according to a clustering algorithm.
As an example, the terminal checks whether the number of array combinations are calculated according to a preset array combination requirement, if the terminal judges that the number of array combinations are calculated, the terminal clusters the newly added test design points according to a preset clustering algorithm to obtain clustering center points of the newly added test design points, and the terminal takes the clustering center point position data of the newly added test design points as clustering center point position data; if the terminal judges that the arrangement number combination is not calculated, the terminal deletes the current arrangement number in the arrangement number set, redetermines new test design points aiming at the arrangement number set, and generates the arrangement number combination according to the new test design points and constraint test design points until the arrangement number combination meets the preset arrangement number combination requirement.
Step S210, distance data between the clustering center points and the constraint test design points are determined, and a target test design point set is generated according to the distance data and the clustering center points.
The distance data may be data representing a distance between a clustering center point of the new test design point obtained after the new test design point is clustered and a constraint test design point.
The target test design point set may be a set of test design points capable of representing complex constraint relationships between variables in dimensions in a non-hypercube space.
As an example, the terminal obtains the distance between the clustering center point of the newly added experimental design point obtained after the clustering of the newly added experimental design point and the constraint experimental design point, and if the distance represents that the clustering center point of the newly added experimental design point is too close to the constraint experimental design point, the terminal takes a set formed by the clustering center point of the newly added experimental design point and the constraint experimental design point as a target experimental design point set; if the distance represents that the clustering center point of the newly added test design point is not too close to the constraint test design point, ending the test design point construction flow by the terminal.
In the Latin hypercube design method suitable for the non-hypercube constraint space, constraint test design points are screened out from an initial test design point set according to preset constraint conditions, so that initial test design points meeting the preset constraint conditions are screened out from the initial test design point set containing the initial test design points distributed on a preset number of dimensions to serve as constraint test design points, and preliminary determination of the test design points is realized; generating a permutation number combination according to a preset number of dimensions, so as to determine a permutation number set and a permutation combination according to preset dimension combination requirements; determining newly added test design points for the array number combination, so as to determine the positions of the newly added test design points for each dimension in the array number combination according to a preset arrangement mode; under the condition that the array combination meets the preset array combination requirement, clustering the newly-added test design points according to a preset clustering algorithm to obtain clustering center points, so as to cluster the newly-added test design points and determine the clustering center corresponding to the newly-added test design points; determining distance data between a clustering center point and constraint test design points, generating a target test design point set according to the distance data and the clustering center point, selecting a clustering center or other test design points to add the constraint test design points based on the distance between the clustering center and the original test design points, further determining the target test design point set, screening out the constraint test design points meeting requirements from the initial test design points, combining a preset number of dimensions, determining array combination formed by a plurality of dimensional combinations, determining the corresponding positions of the newly-added test design points in each dimension in the array combination according to a preset test design point newly-adding mode, selecting the clustering center or other test design points to add the constraint test design points based on the distance between the clustering center obtained by clustering the newly-added test design points and the constraint test design points under the condition that the array combination meets preset requirements, further determining the target test design point set, selecting the test design points capable of fully representing data characteristics in the non-super-cube space under the condition of considering complex constraint relation among variables in each dimension, and guaranteeing uniformity of the test design points in the non-super-cube space, and further improving the efficiency of the test design.
In some embodiments, before the constraint test design points are selected from the initial test design point set according to the preset constraint condition, the method further includes: generating a random test design point set according to the initial test design points and the preset number of dimensions; obtaining row vectors corresponding to the random test design point set, and carrying out local search on the row vectors according to a preset local search mode to obtain a first intermediate test design point set; according to a preset disturbance strategy, the first intermediate test design point set is disturbed to obtain a second intermediate test design point set; carrying out local search on the second intermediate test design point set according to a preset local search mode to obtain a third intermediate test design point set; and under the condition that the third intermediate test design point set meets the preset termination condition, the third intermediate test design point set is used as the initial test design point set.
Wherein, the set of random trial design points may refer to a set of several random trial design points.
The row vector may refer to an object that performs a local search operation on random trial design points in the set of random trial design points.
The preset local search mode may be a mode of optimally selecting or screening random test design points in the random test design point set.
The first intermediate test design point set may refer to a test design point set obtained by performing local search on a row vector corresponding to the random test design point set.
The preset disturbance strategy may refer to a strategy adopted when the first intermediate test design point set is disturbed, and in practical application, the preset disturbance strategy may include a cyclic sequence exchange disturbance strategy.
The second set of intermediate design points may refer to a set of design points obtained by perturbing the first set of intermediate design points.
The third set of intermediate design points may be a set of design points obtained by performing local search on a row vector corresponding to the second set of intermediate design points.
The preset termination condition may be data for determining whether the local search operation for the set of intermediate trial design points can be ended.
As an example, the terminal normalizes the design space such that each variable dimension is [0,1], the terminal generates an initial design for experiment OLHD (n, k) based on a multi-criteria optimal latin hypercube design (Latin Hypercube Design, LHD), specifically, n represents the number of design points for experiment, k represents the number of design variable dimensions as an example, and the multi-criteria optimal LHD can be described as follows: the terminal generates a random Latin hypercube design LHD (n, k) consisting of n initial test design points or random test design points and k dimensions, which is recorded as a random test design point set Y0, and selects an object for performing local search operation, namely a row vector corresponding to the test design points, specifically, the method for selecting the row vector for the local search operation is as follows: firstly, according to Euclidean distance calculation formula, the distances of all test design points in the design space are calculated in pairs to form a distance matrix of n, and the distance matrix of n can be expressed as:
The terminal sorts the distance values except 0 from small to large into { D }, according to the calculation result of the distances of the test design points 1 ,D 2 ,…,D s And obtain a test corresponding to each distanceDesign point pair (x) i ,x j ) In addition, the test design point x with the smallest distance from other test design points is calculated m The test design point x m Can be expressed as:
when x is m Belonging to the distance D 1 A test design point pair in a set v (X) of test design point pairs, the test design point pair being selected; when x is m Not of distance D 1 A certain test design point pair in the set of test design point pairs is used for judging the composition distance D 1 Is isolated from x in the test design point of (2) m The nearest test design point is selected, one test design point pair formed by the test design points is selected, finally, row vectors corresponding to the two test design points of the selected test design point pair are objects of matrix local search, the terminal carries out local search operation on the row vectors, a new Latin hypercube design is determined, the Latin hypercube design is recorded as a first middle test design point set Y1, disturbance strategy is adopted to carry out disturbance on the Y1 so as to obtain a new matrix after disturbance, namely a second middle test design point set Y2, the second middle test design point set Y2 is used for a local search process, the terminal carries out local search operation on the Y2 again to obtain Y3, whether Y3 is superior to Y2 is judged according to a set judgment index, if the judgment result is yes, the Y2 is equal to Y3; if the judgment result is no, the terminal judges whether the set termination condition is met, if the judgment result is yes, the circulation is stopped, otherwise, the method returns to the step of adopting the disturbance strategy to carry out disturbance on Y1, and further, the local search process can be expressed as follows: at 1 <i<n,1<j<In the case of n, if i is not equal to j and the intersection of { i, j } and v (X) is not an empty set, then for any 1<l<k,x i And x j The first bit element of (2) is replaced to obtain a new matrix Y, and if the new matrix Y is superior to the initial matrix X according to the acceptance criterion Y, X=Y; the perturbation columns employed by the perturbation strategy are determined by the orthogonality index between the column vectors. Calculating the correlation coefficients of the two-by-two according to a Pearson correlation coefficient calculation formula to form a k-by-k correlation coefficient matrix,the correlation coefficient matrix of k is expressed as:
in the correlation coefficient matrix, when i+.j, ρ ijji ρ is in the range of [ -1,1]. Meanwhile, considering that the correlation represented by ρ= -x and ρ=x is the same, the elements in the correlation coefficient matrix may be represented by their absolute values; through analysis of the correlation coefficient matrix, the two design variables with the greatest correlation can be found first, { (c) i ,c j )|maxρ=ρ ij I+.j }; in addition, the design variable c with the greatest total correlation with other design variables is found according to the sum of the correlation coefficients of each row variable and other row variables t ,c t Can be expressed as:
when c t Is c i And c j In one column, then c t ={c 1t ,c 2t ,…,c nt -a column selected for perturbation; if not, c i And c j In (c) t The column with the greater correlation is selected. After the process, when selecting the target column, the column with the largest correlation and the column with the largest total correlation in the matrix can be simultaneously considered.
In the embodiment, a random test design point set is generated according to the initial test design points and the preset number of dimensions; obtaining row vectors corresponding to the random test design point set, and carrying out local search on the row vectors according to a preset local search mode to obtain a first intermediate test design point set; according to a preset disturbance strategy, the first intermediate test design point set is disturbed to obtain a second intermediate test design point set; carrying out local search on the second intermediate test design point set according to a preset local search mode to obtain a third intermediate test design point set; in the case that the third set of intermediate design points meets the preset termination conditionThe third intermediate test design point set is used as an initial test design point set, and the initial test design point set can be generated based on the initial test design points and the preset number of dimensions in a local search, disturbance and other modes, so that a data basis is provided for the combination and the new addition of the subsequent test design points; the judgment criterion adopted for judging whether Y3 is better than Y2 is the comprehensive judgment of the spatial orthogonality and uniformity of the LHD matrix, wherein the uniformity utilizes phi p The criterion makes the determination, while the orthogonality makes the determination using the total linear correlation coefficient between column vectors, which can be expressed as:
φ p The criterion is expressed as that for one test design D, the distance D between two test design points in D is calculated ij By means of the distance value d m Ordering to obtain a sequence of characterization pairs (J 1 ,…,J m ,…,J s ) Wherein d is m Representing different distance values and satisfying d 1 <…<d m <…<d s ,J m Indicating a distance value d m Logarithm of experimental design points of (a). Phi (phi) p The expression of (2) can be expressed as:
wherein t may be 1 or 2.
The association of orthogonality criterion with homogeneity criterion is done by means of weight aggregation, taking into account ρ 2 Is in the range of [0,1]]Weight is set for convenience, and phi is also required p And (5) carrying out normalization processing on the index. Phi (phi) p The metrics each satisfy a metric constraint, which can be expressed as:
wherein p represents phi p The hyper-parameter p, ceil (x) in the index represents the rounding-up function, floor (x) represents the rounding-down function.
Wherein, the variable x in floor (x) can be expressed as:
finally, the formed judgment index can be expressed as:
wherein ω is a super parameter representing the weight, and it is equally important to characterize both when ω=0.5, with values in the range of [0,1 ].
In some embodiments, generating the permutation number combination according to the preset number of dimensions includes: combining a preset number of dimensions according to a preset combination mode to obtain a dimension combination; from the dimensional combinations, a permutation number combination is generated.
The preset combination mode may be a mode of combining a plurality of dimensions into one dimension combination.
The dimension combination may refer to a combination relationship among a plurality of dimensions, and in practical application, the dimension combination may include at least two dimensions.
As an example, the terminal performs a plurality of combinations on a preset number of dimensions according to a preset combination mode to obtain a plurality of dimension combinations, each dimension combination can include a plurality of dimensions, the terminal arranges the plurality of dimension combinations according to a specific arrangement mode to obtain an arrangement number combination, further, the terminal can also obtain dimension values (position data) of constraint test design points in each dimension combination, and the terminal performs small-to-large arrangement on the constraint test design points according to the data of the dimension values.
In this embodiment, a preset number of dimensions are combined according to a preset combination mode to obtain a dimension combination; according to the dimension combinations, the arrangement number combinations are generated, constraint relations among the dimensions in the dimension combinations can be fully considered, data characteristics of data in different dimensions in the non-hypercube space can be obtained, and further the acquisition efficiency of test design points is improved.
In some embodiments, determining an additional trial design point for the set of arranged numbers includes: obtaining distance difference data of constraint test design points in a first target dimension; screening a distance difference maximum value from the distance difference data, and obtaining a target constraint test design point corresponding to the distance difference maximum value; and acquiring the position data of the target constraint test design point on the first target dimension, and determining the position data corresponding to the newly-added test design point aiming at the first target dimension according to the position data.
The first target dimension may be a first dimension corresponding to a target dimension combination in the permutation number set, in practical application, the target dimension combination a includes 2 dimensions p and q, and then a 1 st dimension in a dimension combination relationship represented by the target dimension combination a is a p dimension, and a 2 nd dimension is a q dimension.
The distance difference data may refer to data representing a difference value between position data of the constraint test design points in the first target dimension, in practical application, the distance difference data may include representing a distance between any two constraint test design points, for example, the position data corresponding to the first constraint test design point M1 in the first target dimension is p1, the position data corresponding to the second constraint test design point M2 is p2, and then the distance difference data may be represented as p12=p1-p 2, and in practical application, an absolute value of p12 may be taken as the distance difference data.
The maximum value of the distance difference may be the distance difference data with the largest value among the plurality of distance difference data.
The target constraint test design point corresponding to the maximum value of the distance difference may refer to a constraint test design point associated with the distance difference data corresponding to the maximum value of the distance difference, for example, the position data corresponding to the first constraint test design point M1 in the first target dimension may be p1, the position data corresponding to the second constraint test design point M2 may be p2, the position data corresponding to the third constraint test design point M3 may be p3, the distance difference data between the first constraint test design point and the second constraint test design point may be p12=p1-p 2, the distance difference data between the first constraint test design point and the third constraint test design point may be p13=p1-p 3, the distance difference data between the second constraint test design point and the third constraint test design point may be p23=p2-p 3, and if p23 is the maximum value of the distance difference data p12, p13 and p23, the distance difference data corresponding to the third constraint test design point and the second constraint test design point may be the target constraint test design point corresponding to the maximum value of the distance difference p 23.
The position data of the target constraint test design point in the first target dimension may refer to a dimension value of the target constraint test design point in the first target dimension.
The position data corresponding to the new test design point for the first target dimension may refer to a dimension value of the new test design point in the first target dimension.
As an example, the position data corresponding to the first constraint test design point M1 on the first target dimension is p1, the position data corresponding to the second constraint test design point M2 is p2, the position data corresponding to the third constraint test design point M3 is p3, the terminal determines the distance difference data of the constraint test design point on the first target dimension according to the position data of the constraint test design point on the first target dimension, the distance difference data between the first constraint test design point and the second constraint test design point may be represented as p12=p1-p 2, the distance difference data between the first constraint test design point and the third constraint test design point may be represented as p13=p1-p3, the distance difference data between the second constraint test design point and the third constraint test design point may be represented as p23=p2-p3, the terminal selects the third constraint test design point corresponding to the distance difference maximum value p23 and the second constraint test design point from the distance difference data p12, p13 and p23 from the distance difference data, and obtains the position data of the terminal corresponding to the first constraint test design point in the first target dimension of p 2+p2, and the position data of the terminal is determined according to the new position data of the first constraint test design point of p 1+p2.
In the embodiment, distance difference data of constraint test design points in a first target dimension is obtained; screening a distance difference maximum value from the distance difference data, and obtaining a target constraint test design point corresponding to the distance difference maximum value; the position data of the target constraint test design points in the first target dimension is obtained, the position data corresponding to the newly added test design points aiming at the first target dimension is determined according to the position data, the positions of the newly added test design points in the target dimension can be determined based on the position data of the constraint test design points in the target dimension, and the accuracy of the positions of the newly added test design points is improved.
In some embodiments, after determining the position data corresponding to the new design point for the first target dimension, the method further includes: acquiring a search step length and a search range aiming at a second target dimension; according to a preset searching mode, determining candidate position data of a newly added test design point aiming at a second target dimension in a searching range; and taking the candidate position data meeting the requirement of the preset newly added test design point as the position data of the newly added test design point aiming at the second target dimension.
The search step for the second target dimension may refer to the number of elements (i.e., the number of design points) that are spanned during the search or the lookup of the design points.
The search range may refer to an execution range of a search or search operation in searching or searching for the trial design point.
The second target dimension may refer to a dimension after the first target dimension in the target dimension combination.
The preset searching mode may refer to a data searching mode based on a step size and a range.
The candidate position data of the newly added trial design point for the second target dimension may refer to a dimension value of the trial design point found or searched in the second target dimension.
The preset new design point requirement may be data for determining whether the design point can be used as the new design point.
Wherein the new design of trial point for the second target dimension may refer to the position data of the new design of trial point in the second target dimension.
As an example, the terminal obtains a search step length for the second target dimension, the terminal may determine a search range as an intersection between a position of the newly added trial design point on the first target dimension and the second target dimension, the terminal searches the position of the newly added trial design point in the search range with the search step length according to a preset search mode, and the terminal uses the searched position data as candidate position data of the newly added trial design point for the second target dimension; and the terminal checks whether the candidate position data meets the requirement of a preset newly-added test design point, and the position data passing the check can be used as the position data of the newly-added test design point aiming at the second target dimension.
In this embodiment, the search step length and the search range for the second target dimension are obtained; according to a preset searching mode, determining candidate position data of a newly added test design point aiming at a second target dimension in a searching range; candidate position data meeting the requirement of a preset newly-added test design point is used as position data of the newly-added test design point aiming at the second target dimension, searching can be conducted within a preset range based on a preset step length, the position data of the newly-added test design point on the second target dimension is determined, and accuracy of the position data of the newly-added test design point is improved.
In some embodiments, generating a set of target trial design points from the distance data and the cluster center points includes: generating a target test design point set according to the clustering center points and constraint test design points corresponding to the clustering center position data under the condition that the distance data is larger than or equal to a preset distance threshold value; and screening out replacement test design points from the newly-added test design points corresponding to the clustering center points under the condition that the distance data is smaller than a preset distance threshold value, and generating a target test design point set according to the replacement test design points and the constraint test design points.
The preset distance threshold may be data for determining whether the clustering center point and the constraint test design point may form a target test design point set.
The clustering center position data may refer to position data of a center point obtained after clustering the newly added test design points.
The replacement test design points may be test design points for replacing the clustering center points and forming a target test design point set with the constraint test design points.
As an example, in the case that the distance data is greater than or equal to a preset distance threshold, the terminal uses a cluster center point corresponding to the cluster center position data and a test design point set formed by constraint test design points as a target test design point set; under the condition that the distance data is smaller than a preset distance threshold value, a plurality of newly-added test design points can form a test design point group after clustering, namely, a clustering center point is a center point corresponding to a plurality of newly-added test design points in the newly-added test design point group, a terminal screens out replacement test design points from the newly-added test design points in the newly-added test design point group corresponding to clustering center position data, the terminal generates a target test design point set by using the replacement test design points and constraint test design points, further, if the distance data corresponding to the clustering center point Z1Z of the two newly-added test design point groups Z1 and Z2 are L1, the clustering center point Z2Z of the Z1 is L2, the preset distance threshold value can be expressed as L0, if L1 is smaller than L0, L2 is larger than L0, the terminal reselects the new-added test design points from the Z1 to serve as the replacement test design points Z1T, and the target test design point set is formed by the constraint test design points by using Z1T, Z Z and the terminal.
In the embodiment, under the condition that the distance data is larger than or equal to a preset distance threshold, the terminal generates a target test design point set according to the clustering center point and the constraint test design point corresponding to the clustering center position data; under the condition that the distance data is smaller than a preset distance threshold value, selecting a replacement test design point from newly-added test design points corresponding to the clustering center position data, generating a target test design point set according to the replacement test design point and the constraint test design point, and selecting the clustering center or the replacement test design point to form the target test design point set with the constraint test design point based on the distance between the clustering center and the constraint test design point, so that the clustering center and the constraint test design point are prevented from being too close, and further the acquisition efficiency of the test design point is improved.
In some embodiments, clustering the newly added test design points according to a preset clustering algorithm to obtain a clustering center point, including: screening a center point from the newly added test design points; classifying the newly added test design points according to the distance data between the newly added test design points and the center point to obtain test design point groups; determining grouping center points corresponding to the grouping of the test design points, and taking the grouping center points as clustering center points of the grouping of the test design points corresponding to the grouping center points under the condition that the position information of the grouping center points meets the preset clustering requirement.
The center point may be a center test design point of the newly added test design points.
Wherein, the distance data between the newly added trial design point and the center point may refer to data characterizing the distance between the newly added trial design point and the center point.
The grouping of the test design points may be a plurality of groups of test design points obtained by classifying the newly added test design points based on distance data between the newly added test design points and the center point.
The grouping center point corresponding to the grouping of the test design points may refer to a test design point that may be used as a center in a new test design point in a certain test design point grouping.
The position information of the group center point may refer to a dimension value or a coordinate value of the group center point in each dimension.
The preset clustering requirement may be data for determining whether the grouping center point can be used as a clustering center point.
As an example, the terminal screens (or randomly selects) one newly-increased test design point from the newly-increased test design points as a center point, classifies the newly-increased test design points according to distance data between the newly-increased test design points and the center point to obtain test design point groups, for example, the terminal classifies the distance data between the newly-increased test design points and the center point by using data C as a threshold, the terminal may divide the newly-increased test design points into two test design point groups, the terminal calculates a grouping center point corresponding to the test design point groups, the terminal updates the grouping center point into a new center point, the terminal calculates distance data between each newly-increased test design point and the new center point again and classifies the new center point, updates the center point until the position data of the grouping center point is not changed, at this time, the terminal judges that the position information of the grouping center point meets a preset clustering requirement, the terminal uses the grouping center point as a clustering center point of the test design point group corresponding to the grouping center point group, and the terminal uses the position data of the clustering center point corresponding to the test design point group as the clustering center point position data.
In the embodiment, the center point is selected from the newly added experimental design points; classifying the newly added test design points according to the distance data between the newly added test design points and the center point to obtain test design point groups; determining grouping center points corresponding to the grouping of the test design points, and taking the grouping center points as clustering center points of the grouping of the test design points corresponding to the grouping center points under the condition that the position information of the grouping center points meets the preset clustering requirement; the position data corresponding to the clustering center points of the test design point groups are used as the clustering center point position data, so that the newly added test design points can be clustered rapidly and conveniently, the data characteristics of the newly added test design points are fully considered, and the acquisition efficiency of the test design points is improved.
In some embodiments, as shown in fig. 3, a flow diagram of a latin hypercube design method applicable to non-hypercube constraint spaces is provided, S1: the terminal standardizes the design space to make each variable dimension be [0,1 ]]An initial design of experiment OLHD (n, k) is generated based on a multi-criterion optimal LHD method, where the multi-criterion optimal LHD can be described as follows, n representingTest design points, k represents design variable dimension number: a0: generating a random Latin hypercube design LHD (n, k) consisting of n test design points and k dimensions, denoted as Y0; a1: selecting an object for local search operation, namely a row vector corresponding to the test design point, and carrying out local search operation on the row vector to determine a new Latin hypercube design Y1; a2: disturbing the Y1 by adopting a disturbance strategy to obtain a new disturbed matrix Y2 for a local search process; a3: and carrying out local search operation of A1 on Y2 to obtain Y3, judging whether Y3 is better than Y2 according to the set judging index, and if so, enabling Y2 to be equal to Y3. If the judgment result is negative, directly turning to A4; a4: judging whether the set termination condition is met, if yes, stopping circulation, otherwise, jumping to A2; s2: judging the obtained OLHD (n, k) according to the constraint condition; let t points satisfy constraint conditions, t <n, the t test design points form a set X 0 The method comprises the steps of carrying out a first treatment on the surface of the S3: from the dimension number k, a set of permutation numbers is generated. Assuming that the number of the first dimension combination of the array number set is p, to satisfy the projection characteristic of the LHD, the number of the first dimension combination is calculated as the number of the first dimension combination of the array number set is calculated as the number of the first dimension combination 0 All test design points in the test are arranged from small to large to obtain X 1 ={x 1 ,x 2 ,…,x t 0 therein<x 1p <x 2p <…<x tp <1, a step of; s4: and arranging the newly added test design points in the dimension p according to the distances among the test design points. Calculating the distance value between each test design point on the dimension p, and obtaining a distance value set D by including the distance between the test design point with the minimum dimension value and the boundary 0 and the distance between the test design point with the maximum dimension value and the boundary 1 1 ={d 1 ,d 2 ,…,d t+1 }. To determine the newly added test design point x t+1 The position in dimension p is found first a set of distance values D 1 Two test design points x corresponding to the greatest distance i And x i+1 And test design point x t+1 Placed at x along dimension p i And x i+1 Intermediate position of (1), i.e. satisfy x (t+1)p =(x ip +x (i+1)p ) 2, recalculating the respective testUpdating the distance value of the test design point in the dimension p to obtain a distance value set D 2 . For the newly added point x t+2 To x n Repeating the above process, and fixing the position of the newly added test design point in the dimension p; s5: and determining the positions of the newly added test design points in other dimensions. Assuming that the number of the second dimension of the first dimension combination of the array number set is q, the design point x is tested t+1 For example, in determining x t+1 In the case of the position in the direction of the dimension q, it is necessary to search for the optimal position in the direction of the dimension q with a fixed step length λ according to the position in the dimension p, the search range being according to x (t+1)p And (3) determining the optimal position according to the judgment index applied in the step A3 in the step S1. When x is t+1 After the optimal position in dimension q is determined, it is added to the determined design points for trial and x is further determined t+2 And (3) the optimal position in the dimension q until the positions of all the test design points in the dimension q are determined. In addition, in order to ensure the projective performance, the position value of the test design point generated by the preamble in the dimension q is not acquired by the test design point generated subsequently; for the 3 rd dimension to the kth dimension, a similar method is adopted to search the optimal position of the object in the corresponding dimension. After the first dimension combination of the permutation number set is searched according to the dimension sequence, searching the optimal test design points of the second dimension combination until the searching of the optimal test design points of all the dimension combinations is completed, and generating H newly added test design points in total, wherein H can be expressed as:
wherein A represents the number of rows. S6: combining the newly added test design points with the original reserved point set; s7: judging whether the number of the arranged combinations is calculated, if so, continuing to step S8, otherwise, deleting the current number of the arranged combinations in the arranged number set, and then jumping to S4; s8: clustering is carried out according to a K-means clustering algorithm. The generated H newly-added test design points are clustered by using a K-means method, and the number of clusters is set as (n-t) classes; s9: judging whether the K-means clustering center is too close to the original test design point, if so, continuing to step S10, otherwise, ending the construction flow; s10: and selecting the centers of the (n-t) classes as the finally newly added (n-t) test design points to form a Latin hypercube design CLHD (n, k) which finally meets constraint conditions, and if the Euclidean distance between a certain cluster center and the originally existing test design points in the design space is smaller than a set threshold value, reselecting the test design point with the optimal judgment index applied in the step A3 in the step S1 from the class corresponding to the cluster center to replace the cluster center point, and adding the test design point into a final newly added test design point set.
In some embodiments, the Latin hypercube design method proposed in the validation for non-hypercube constrained spaces is implemented with an example problem under a two-dimensional non-hypercube constrained space defined as 1/4 circles in a first quadrant in two dimensions, where 1/4 circles in the first quadrant can be expressed as:
firstly, generating initial OLHD (100, 2) by step S1, wherein the distribution of the experimental design points and the boundary of the constraint space of the OLHD in the two-dimensional space are shown as shown in figure 4, providing a schematic diagram of the distribution of the experimental design points and the boundary of the constraint space, wherein 21 points in 100 experimental design points do not meet constraint conditions, so that a large-area blank area without the experimental design points exists in the constraint space, and the data information of the area is lost. To solve this problem, the initial OLHD (100, 2) is processed as steps S2 to S10. It should be noted that, when the priority of the selected dimension is changed, the obtained distribution of the new design points is different, as shown in fig. 5, a distribution diagram of the new design points is provided, when the dimension x1 is selected first, the new design points are more close to the x1 axis, as shown in fig. 6, a distribution diagram of the new design points is provided, when the dimension x2 is selected first, the new design points are more close to the x2 axis, so that all new design points generated for different dimension selection sequences using the K-means algorithm And carrying out clustering analysis on the points to consider the influence of the dimension selection sequence on the result, wherein the set category number is the number of the test design points required to be newly added when K-means is clustered. For this two-dimensional problem, the cluster centers of 21 classes are shown in fig. 7, which provides a distribution schematic diagram of the cluster centers, wherein part of the cluster center points need to be adjusted according to the step described in S10 due to too close distance to a certain point of the 79 points. The distribution of the final two-dimensional test design points CLHD (100, 2) is shown in FIG. 8, which provides a distribution diagram of the two-dimensional test design points, 100 test design points are uniformly distributed in a feasible region phi p A value of 22.8 ρ 2 The value is 0.062. In contrast, if 100 test design points are required to be generated in the feasible region meeting the constraint condition, the number of the sample points of the OLHD is required to be set to 129, which is increased by 29%, the two-dimensional space distribution of the sample points is shown in FIG. 9, and another distribution schematic diagram of the two-dimensional test design points is provided, wherein phi of a point set meeting the constraint condition is the same p A value of 21.4 ρ 2 The value was 0.088.
In this embodiment, the initial test design point set is processed, and the new test design points needing to be added into the initial test design point set are subjected to cluster analysis, and the target test design point set is output by combining the cluster result, so that the generated latin hypercube design has good spatial uniformity and orthogonality in the constraint space, and meanwhile, invalid test design points which do not meet the constraint condition are avoided, so that the data characteristics in the constraint space are accurately captured.
It should be understood that, although the steps in the flowcharts related to the embodiments described above are sequentially shown as indicated by arrows, these steps are not necessarily sequentially performed in the order indicated by the arrows. The steps are not strictly limited to the order of execution unless explicitly recited herein, and the steps may be executed in other orders. Moreover, at least some of the steps in the flowcharts described in the above embodiments may include a plurality of steps or a plurality of stages, which are not necessarily performed at the same time, but may be performed at different times, and the order of the steps or stages is not necessarily performed sequentially, but may be performed alternately or alternately with at least some of the other steps or stages.
Based on the same inventive concept, the embodiment of the application also provides a Latin hypercube design device suitable for the non-hypercube constraint space, which is used for realizing the Latin hypercube design method suitable for the non-hypercube constraint space. The implementation of the solution provided by the device is similar to the implementation described in the above method, so the specific limitation in the embodiments of the latin hypercube design device for non-hypercube constraint space provided below can be referred to above for the limitation of the latin hypercube design method for non-hypercube constraint space, and will not be repeated here.
In one embodiment, as shown in FIG. 10, there is provided a Latin hypercube design apparatus adapted for use with non-hypercube constrained spaces, comprising: the system comprises a test design point screening module 1002, a combination generating module 1004, a test design point adding module 1006, a test design point clustering module 1008 and a set determining module 1010, wherein:
the test design point screening module 1002 is configured to screen constraint test design points from the initial test design point set according to a preset constraint condition; the initial test design point set comprises initial test design points distributed on a preset number of dimensions; the constraint test design point is the initial test design point meeting the preset constraint condition.
The combination generating module 1004 is configured to generate a permutation number combination according to the preset number of dimensions.
And a test design point adding module 1006, configured to determine a new test design point for the combination of the number of rows.
And the test design point clustering module 1008 is configured to cluster the newly added test design points according to a preset clustering algorithm to obtain a cluster center point when the permutation and combination meets a preset permutation and combination requirement.
And the set determining module 1010 is configured to determine distance data between the cluster center point and the constraint test design point, and generate a target test design point set according to the distance data and the cluster center point.
In an exemplary embodiment, the apparatus further includes a test design point acquisition module, where the test design point acquisition module is specifically configured to generate a random test design point set according to the initial test design point and the preset number of dimensions; obtaining row vectors corresponding to the random test design point set, and carrying out local search on the row vectors according to a preset local search mode to obtain a first intermediate test design point set; according to a preset disturbance strategy, the first intermediate test design point set is disturbed to obtain a second intermediate test design point set; according to the preset local searching mode, carrying out local searching on the second intermediate test design point set to obtain a third intermediate test design point set; and taking the third intermediate test design point set as the initial test design point set under the condition that the third intermediate test design point set meets a preset termination condition.
In an exemplary embodiment, the combination generating module 1004 is specifically further configured to combine the preset number of dimensions according to a preset combination manner to obtain a dimension combination; the combination of dimensions includes at least two dimensions; and generating the arrangement number combination according to the dimension combination.
In an exemplary embodiment, the above-mentioned new test design point adding module 1006 is specifically further configured to obtain distance difference data of the constraint test design point in the first target dimension; the first target dimension is a first dimension corresponding to a target dimension combination in the permutation number set; the distance difference data represents the distance between any two constraint test design points; screening a distance difference maximum value from the distance difference data, and acquiring a target constraint test design point corresponding to the distance difference maximum value; and acquiring the position data of the target constraint test design point on the first target dimension, and determining the position data corresponding to the newly-added test design point aiming at the first target dimension according to the position data.
In an exemplary embodiment, the apparatus further includes a trial design point addition module, where the trial design point addition module is specifically configured to obtain a search step size and a search range for the second target dimension; the second target dimension is the dimension after the first target dimension in the target dimension combination; according to a preset searching mode, determining candidate position data of a newly added experimental design point aiming at the second target dimension in the searching range; and taking the candidate position data meeting the requirement of the preset newly-added test design point as the position data of the newly-added test design point aiming at the second target dimension.
In an exemplary embodiment, the above-mentioned set determining module 1010 is specifically further configured to generate the target set of test design points according to the cluster center point and the constraint test design point if the distance data is greater than or equal to a preset distance threshold; and screening out a replacement test design point from the newly-increased test design points corresponding to the clustering center point under the condition that the distance data is smaller than the preset distance threshold value, and generating the target test design point set according to the replacement test design point and the constraint test design point.
In an exemplary embodiment, the test design point clustering module 1008 is specifically further configured to screen a center point from the newly added test design points; classifying the newly added test design points according to the distance data between the newly added test design points and the center point to obtain test design point groups; determining grouping center points corresponding to the grouping of the test design points, and taking the grouping center points as clustering center points of the grouping of the test design points corresponding to the grouping center points under the condition that the position information of the grouping center points meets the preset clustering requirement.
The various modules in the latin hypercube design apparatus described above as suitable for non-hypercube constrained spaces may be implemented in whole or in part in software, hardware, and combinations thereof. The above modules may be embedded in hardware or may be independent of a processor in the computer device, or may be stored in software in a memory in the computer device, so that the processor may call and execute operations corresponding to the above modules.
In one embodiment, a computer device is provided, which may be a terminal, and the internal structure thereof may be as shown in fig. 11. The computer device includes a processor, a memory, an input/output interface, a communication interface, a display unit, and an input means. The processor, the memory and the input/output interface are connected through a system bus, and the communication interface, the display unit and the input device are connected to the system bus through the input/output interface. Wherein the processor of the computer device is configured to provide computing and control capabilities. The memory of the computer device includes a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system and a computer program. The internal memory provides an environment for the operation of the operating system and computer programs in the non-volatile storage media. The input/output interface of the computer device is used to exchange information between the processor and the external device. The communication interface of the computer device is used for carrying out wired or wireless communication with an external terminal, and the wireless mode can be realized through WIFI, a mobile cellular network, NFC (near field communication) or other technologies. The computer program, when executed by a processor, implements a Latin hypercube design method applicable to non-hypercube constrained spaces. The display unit of the computer device is used for forming a visual picture, and can be a display screen, a projection device or a virtual reality imaging device. The display screen can be a liquid crystal display screen or an electronic ink display screen, and the input device of the computer equipment can be a touch layer covered on the display screen, can also be a key, a track ball or a touch pad arranged on the shell of the computer equipment, and can also be an external keyboard, a touch pad or a mouse and the like.
It will be appreciated by those skilled in the art that the structure shown in fig. 11 is merely a block diagram of a portion of the structure associated with the present application and is not limiting of the computer device to which the present application applies, and that a particular computer device may include more or fewer components than shown, or may combine some of the components, or have a different arrangement of components.
In an embodiment, there is also provided a computer device comprising a memory and a processor, the memory having stored therein a computer program, the processor implementing the steps of the method embodiments described above when the computer program is executed.
In one embodiment, a computer-readable storage medium is provided, on which a computer program is stored which, when executed by a processor, carries out the steps of the method embodiments described above.
In an embodiment, a computer program product is provided, comprising a computer program which, when executed by a processor, implements the steps of the method embodiments described above.
It should be noted that, the user information (including, but not limited to, user equipment information, user personal information, etc.) and the data (including, but not limited to, data for analysis, stored data, presented data, etc.) referred to in the present application are information and data authorized by the user or sufficiently authorized by each party, and the collection, use, and processing of the related data are required to meet the related regulations.
Those skilled in the art will appreciate that implementing all or part of the above described methods may be accomplished by way of a computer program stored on a non-transitory computer readable storage medium, which when executed, may comprise the steps of the embodiments of the methods described above. Any reference to memory, database, or other medium used in the various embodiments provided herein may include at least one of non-volatile and volatile memory. The nonvolatile Memory may include Read-Only Memory (ROM), magnetic tape, floppy disk, flash Memory, optical Memory, high density embedded nonvolatile Memory, resistive random access Memory (ReRAM), magnetic random access Memory (Magnetoresistive Random Access Memory, MRAM), ferroelectric Memory (Ferroelectric Random Access Memory, FRAM), phase change Memory (Phase Change Memory, PCM), graphene Memory, and the like. Volatile memory can include random access memory (Random Access Memory, RAM) or external cache memory, and the like. By way of illustration, and not limitation, RAM can be in the form of a variety of forms, such as Static Random access memory (Static Random access memory AccessMemory, SRAM) or dynamic Random access memory (Dynamic Random Access Memory, DRAM), and the like. The databases referred to in the various embodiments provided herein may include at least one of relational databases and non-relational databases. The non-relational database may include, but is not limited to, a blockchain-based distributed database, and the like. The processors referred to in the embodiments provided herein may be general purpose processors, central processing units, graphics processors, digital signal processors, programmable logic units, quantum computing-based data processing logic units, etc., without being limited thereto.
The technical features of the above embodiments may be arbitrarily combined, and all possible combinations of the technical features in the above embodiments are not described for brevity of description, however, as long as there is no contradiction between the combinations of the technical features, they should be considered as the scope of the description.
The above examples only represent a few embodiments of the present application, which are described in more detail and are not to be construed as limiting the scope of the present application. It should be noted that it would be apparent to those skilled in the art that various modifications and improvements could be made without departing from the spirit of the present application, which would be within the scope of the present application. Accordingly, the scope of protection of the present application shall be subject to the appended claims.

Claims (9)

1. A latin hypercube design method suitable for non-hypercube constrained spaces, said method comprising:
generating a random test design point set according to the initial test design points and the preset number of dimensions; obtaining row vectors corresponding to the random test design point set, and carrying out local search on the row vectors according to a preset local search mode to obtain a first intermediate test design point set; according to a preset disturbance strategy, the first intermediate test design point set is disturbed to obtain a second intermediate test design point set; according to the preset local searching mode, carrying out local searching on the second intermediate test design point set to obtain a third intermediate test design point set; under the condition that the third intermediate test design point set meets a preset termination condition, the third intermediate test design point set is used as an initial test design point set; screening constraint test design points from the initial test design point set according to preset constraint conditions; the initial test design point set comprises initial test design points distributed on the preset number of dimensions; the constraint test design points are the initial test design points meeting the preset constraint conditions;
Generating a row number combination according to the preset number of dimensions;
determining a new test design point for the array number combination;
under the condition that the array combination meets the preset array combination requirement, clustering the newly-added test design points according to a preset clustering algorithm to obtain clustering center points;
distance data between the clustering center points and the constraint test design points are determined, and a target test design point set is generated according to the distance data and the clustering center points.
2. The method of claim 1, wherein generating the permutation number combination according to the preset number of dimensions comprises:
combining the preset number of dimensions according to a preset combination mode to obtain a dimension combination; the combination of dimensions includes at least two dimensions;
and generating the arrangement number combination according to the dimension combination.
3. The method of claim 1, wherein the determining the new trial design points for the arrangement of number of combinations comprises:
obtaining distance difference data of the constraint test design point in a first target dimension; the first target dimension is a first dimension corresponding to a target dimension combination in the array number combination; the distance difference data represents the distance between any two constraint test design points;
Screening a distance difference maximum value from the distance difference data, and acquiring a target constraint test design point corresponding to the distance difference maximum value;
and acquiring the position data of the target constraint test design point on the first target dimension, and determining the position data corresponding to the newly-added test design point aiming at the first target dimension according to the position data.
4. A method according to claim 3, wherein after determining the position data corresponding to the new trial design points for the first target dimension, the method further comprises:
acquiring a search step length and a search range aiming at a second target dimension; the second target dimension is the dimension after the first target dimension in the target dimension combination;
according to a preset searching mode, determining candidate position data of a newly added experimental design point aiming at the second target dimension in the searching range;
and taking the candidate position data meeting the requirement of the preset newly-added test design point as the position data of the newly-added test design point aiming at the second target dimension.
5. The method of claim 1, wherein generating a set of target trial design points from the distance data and the cluster center points comprises:
Generating the target test design point set according to the clustering center points and the constraint test design points under the condition that the distance data is larger than or equal to a preset distance threshold value;
and screening out a replacement test design point from the newly-increased test design points corresponding to the clustering center point under the condition that the distance data is smaller than the preset distance threshold value, and generating the target test design point set according to the replacement test design point and the constraint test design point.
6. The method of claim 1, wherein clustering the new design points according to a preset clustering algorithm to obtain a cluster center point comprises:
screening a center point from the newly added test design points;
classifying the newly added test design points according to the distance data between the newly added test design points and the center point to obtain test design point groups;
determining grouping center points corresponding to the grouping of the test design points, and taking the grouping center points as clustering center points of the grouping of the test design points corresponding to the grouping center points under the condition that the position information of the grouping center points meets the preset clustering requirement.
7. A latin hypercube design apparatus adapted for use in a non-hypercube constrained space, said apparatus comprising:
the test design point screening module is used for generating a random test design point set according to the initial test design points and the preset number of dimensions; obtaining row vectors corresponding to the random test design point set, and carrying out local search on the row vectors according to a preset local search mode to obtain a first intermediate test design point set; according to a preset disturbance strategy, the first intermediate test design point set is disturbed to obtain a second intermediate test design point set; according to the preset local searching mode, carrying out local searching on the second intermediate test design point set to obtain a third intermediate test design point set; under the condition that the third intermediate test design point set meets a preset termination condition, the third intermediate test design point set is used as an initial test design point set; screening constraint test design points from the initial test design point set according to preset constraint conditions; the initial test design point set comprises initial test design points distributed on the preset number of dimensions; the constraint test design points are the initial test design points meeting the preset constraint conditions;
The combination generating module is used for generating a row number combination according to the preset number of dimensions;
the test design point adding module is used for determining the new test design points aiming at the arrangement number combination;
the test design point clustering module is used for clustering the newly-added test design points according to a preset clustering algorithm under the condition that the array combination meets the preset array combination requirement to obtain a clustering center point;
and the set determining module is used for determining distance data between the clustering center points and the constraint test design points and generating a target test design point set according to the distance data and the clustering center points.
8. A computer device comprising a memory and a processor, the memory storing a computer program, characterized in that the computer program when executed by the processor implements the steps of the method of any of claims 1 to 6.
9. A computer readable storage medium, on which a computer program is stored, characterized in that the computer program, when being executed by a processor, implements the steps of the method of any of claims 1 to 6.
CN202311378703.3A 2023-10-24 2023-10-24 Latin hypercube design method suitable for non-hypercube constraint space Active CN117113732B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202311378703.3A CN117113732B (en) 2023-10-24 2023-10-24 Latin hypercube design method suitable for non-hypercube constraint space

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202311378703.3A CN117113732B (en) 2023-10-24 2023-10-24 Latin hypercube design method suitable for non-hypercube constraint space

Publications (2)

Publication Number Publication Date
CN117113732A CN117113732A (en) 2023-11-24
CN117113732B true CN117113732B (en) 2024-02-06

Family

ID=88805991

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202311378703.3A Active CN117113732B (en) 2023-10-24 2023-10-24 Latin hypercube design method suitable for non-hypercube constraint space

Country Status (1)

Country Link
CN (1) CN117113732B (en)

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104933261A (en) * 2015-06-29 2015-09-23 北京理工大学 High efficient sequential maximin latin hypercube design method
CN105740592A (en) * 2016-05-05 2016-07-06 中国人民解放军国防科学技术大学 Latin hypercube experiment design method based on sequential sampling
CN109885877A (en) * 2019-01-15 2019-06-14 江苏大学 A kind of constrained domain optimization Latin hypercube design method based on clustering algorithm
CN112434448A (en) * 2021-01-27 2021-03-02 中国人民解放军国防科技大学 Proxy model constraint optimization method and device based on multipoint adding
CN114461741A (en) * 2022-01-24 2022-05-10 北京师范大学 Monitoring sampling point arrangement method and device

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US10503846B2 (en) * 2018-04-22 2019-12-10 Sas Institute Inc. Constructing flexible space-filling designs for computer experiments

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104933261A (en) * 2015-06-29 2015-09-23 北京理工大学 High efficient sequential maximin latin hypercube design method
CN105740592A (en) * 2016-05-05 2016-07-06 中国人民解放军国防科学技术大学 Latin hypercube experiment design method based on sequential sampling
CN109885877A (en) * 2019-01-15 2019-06-14 江苏大学 A kind of constrained domain optimization Latin hypercube design method based on clustering algorithm
CN112434448A (en) * 2021-01-27 2021-03-02 中国人民解放军国防科技大学 Proxy model constraint optimization method and device based on multipoint adding
CN114461741A (en) * 2022-01-24 2022-05-10 北京师范大学 Monitoring sampling point arrangement method and device

Also Published As

Publication number Publication date
CN117113732A (en) 2023-11-24

Similar Documents

Publication Publication Date Title
CN117113732B (en) Latin hypercube design method suitable for non-hypercube constraint space
CN116932935A (en) Address matching method, device, equipment, medium and program product
CN116842171A (en) Article recommendation method, apparatus, computer device and storage medium
CN116894721A (en) Index prediction method and device and computer equipment
CN115063658A (en) Object detection method, device, apparatus, storage medium and program product
CN115409070A (en) Method, device and equipment for determining critical point of discrete data sequence
CN117609412B (en) Spatial object association method and device based on network structure information
CN116882408B (en) Construction method and device of transformer graph model, computer equipment and storage medium
CN114579926B (en) Reduced density matrix reconstruction method, apparatus, device, medium and program product
CN116894964A (en) Later fusion object image clustering method, device and computer equipment
CN115470526A (en) Processing method and device for anti-attack data based on black box model
CN116719994A (en) Media object recommendation method, device, computer equipment and storage medium
CN118331961A (en) Method and device for storing target account in separate storage, computer equipment and readable storage medium
CN116151896A (en) Virtual product recommendation method, device, computer equipment and storage medium
CN117290741A (en) Vehicle clustering method, device, computer equipment and storage medium
CN116881546A (en) Resource recommendation method, device, equipment and storage medium
CN118313789A (en) Pumped storage power station project management scheme screening method
CN117312892A (en) User clustering method, device, computer equipment and storage medium
CN117806863A (en) Defect analysis method, defect analysis device, computer equipment and storage medium
CN118314356A (en) Searching method and device for target network structure, computer equipment and storage medium
CN118607968A (en) Method, apparatus, computer device, readable storage medium, and program product for determining electronic/electrical architecture
CN117150311A (en) Data processing method, device, equipment and storage medium
CN115170296A (en) Method and device for acquiring business object recognition model and computer equipment
CN116894112A (en) Data classification method, device, computer equipment and storage medium thereof
CN116452341A (en) Financial product recommendation method, apparatus, computer device and storage medium

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