Back to Community
Optimization help

I'm using the optimize API with some pretty specific conditions. 99/100 times it works, but occasionally it hits a week where it can't find a solution.

Does anyone have a method for relaxing one of the constraints when a solution can't be found?

1 response

The way, I do it is use CVXPY for optimization and then use quantopian's TargetPortfolioWeights with the weights from CVXPY. This way you are more in control of your optimizations.