Hi Anita, Many thanks for using OpenTURNS. Here are some insight on your problems/questions: 1) Concerning your first question, the AbdoRackwitz algorithm is a gradient-based, local-search optimization algorithm. It stops if any of the following conditions are met: + the maximum iteration number is reached + the optimal point candidate stops to evolve significantly between two iterations (relative error AND absolute error are small) + the projection error is small (the constraint is fulfilled with high accuracy, ie the constraint error is small, AND the gradient of the level function is pointing to the origin with high accuracy, ie the residual error is small)
In your case it stops because of the second condition. Either you are trapped into a local minimum or you have to set the maximum absolute and relative errors to a smaller value than 1e-1. My advice is to spend as much effort as allowed, ie to set all the errors to small values in order to stop the iteration either because you got a *very good* design point or because you tried *really hard* to get such a point. Remember that the optimization problems are solved in the standard space, ie in a Gaussian space excepted if you have a non-Gaussian elliptical copula (you don't). So the absolute and relative errors should be small compared to 1: the input has been normalized. 2) As the AbdoRackwitz algorithm is a gradient-based algorithm, it needs to compute gradients. By default, if you don't provide such gradients, OpenTURNS uses a centered finite difference approximation with a step size optimized to the situation where both the input and the output of your function have been normalized. See here: http://openturns.github.io/user_manual/_generated/openturns.CenteredFiniteDifferenceGradient.html?highlight=centered or here: http://openturns.github.io/user_manual/_generated/openturns.NonCenteredFiniteDifferenceGradient.html?highlight=noncenteredfinite#openturns.NonCenteredFiniteDifferenceGradient to define your own gradient approximation, using either a constant step as shown in the examples or a more advanced step computation, see here: http://openturns.github.io/user_manual/_generated/openturns.BlendedStep.html?highlight=blended#openturns.BlendedStep Cobyla is a gradient-free optimization algorithm, it is why you don't have the warning when using it. 3) The OpenTURNS configuration file (openturns.conf) is an XML file in which all the default values of the parameters of the OpenTURNS algorithms are defined. If OpenTURNS is unable to find it, it switches to default values defined in the ResourceMap object. Normally, the default values defined in openturns.conf and ResourceMap are exactly the same (if not it is a bug), so it should not be the cause of your problem. You can force these values in your script by using ResourceMap like this (to be inserted at the beginning of your script): ResourceMap.SetAsNumericalScalar("CenteredFiniteDifferenceGradient-DefaultEpsilon", 1.0e-5) See http://openturns.github.io/user_manual/_generated/openturns.ResourceMap.html?highlight=resourcemap for the list of available keys. I have no experience on pyinstaller so I cannot help you on this specific part. I hope it will help you to solve your issues. Best regards, Régis LEBRUN >________________________________> De : Anita Laera <[email protected]> >À : [email protected] >Envoyé le : Jeudi 23 juin 2016 18h01 >Objet : [ot-users] FORM - large constraint error > > > >Hi, >I am performing a FORM analysis using AbdoRackwitz() optimization algorithm. >I am coupling my script with a FEM tool. >My questions are: > > >1- I set the maximum iteration number to 100, all the errors less than 0.1 and >the maximum constraint error equal to 10 (I am considering a threshold of 1500 >kPa), but when the analysis finishes the errors are: > > >Iteration number = 5 >Absolute error = 0.001657373913154846 >Relative error = 0.0006446062405829578 >Residual error = 1.0842021724855044e-19 >Constraint error = 138.95327900038 > > >The constraint error is very high. Why does the calculation stop/converge >without trying more iterations to reduce the error? > > >2- When I run the analysis, the following message is displayed: >'WRN - You are using a default implementation for the gradient. Be careful, >your computation can be severely wrong!' >This doesn't happen with Cobyla() but Cobyla() turned to be less accurate for >my case. How to deal with this message? How does it affect my results? > > >3- I have created an executable from my python script. When I run the >executable I get the very large constraint error, while, when I run it through >the interpreter, the constraint error is 3 (and it is correct). Also, when I >run the executable, the following message is shown: >'WRN - The configuration file has not been found, using default parameters' >What does this mean? Is it possible that the creation of the executable >(through pyinstaller) may be the cause of this large error? > > >Thank you in advance for your help! > > >Kind regards, >Anita >_______________________________________________ >OpenTURNS users mailing list >[email protected] >http://openturns.org/mailman/listinfo/users > > > _______________________________________________ OpenTURNS users mailing list [email protected] http://openturns.org/mailman/listinfo/users
