Comments (5)
Also mentioned in this tulip issue.
from polytope.
For now, I support exposing the max_iter
value as a keyword argument. It is not necessarily the best design, but until the best design is found, it would be practical. In more detail, to add max_iter
to the method Polytope.project
, and propagate it to the function projection
, which can the pass it on to projection_iterhull
.
Having said that, this will be a keyword argument, so the choice of default value still remains. Is there a definite sense of what values are large and small, and what should suffice? (the current default is 10**3).
If the value is exposed, and if it is not difficult to pass it in user code, then the default value could be left unchanged.
Another approach (orthogonal to the above) is to add a global constant, which is used as the default keyword argument value (with None
, so that updates at runtime be noticed upon calling the function or method). This was done with ABS_TOL
in the past. User code can then modify the module parameter once just after importing it, much like one picks a backend for matplotlib
.
Even though I do not support global constants much, I think that configuration parameters of solvers are a quite standard use case, and explicit (which is good). A somewhat similar approach is used in dd.cudd
, though there one can set parameters through the manager's constructor (__init__
), something possible just because there is a "manager" concept, which coincidentally serves also as a context of computation (thus holding parameters like memory bounds, reordering tuning parameters, etc., following CUDD's architecture).
from polytope.
Regarding what value is large enough: for the tulip
example we have, I encounter the max_iter
bound error approximately seven times out of eight trials. Since randomization is uniform, multiplying max_iter
by 8 or 10 would be good. But what is good in general depends on the dimension of the polytope. It just samples until it finds a starting simplex or hits the max_iter
bound so having it large will not affect working examples at all since it will keep proceeding with the next step as soon as it finds a solution. The only difference will be: for some examples where it declares the max_iter
error and terminates, it will keep searching and it might find a solution and proceed.
If we want tulip
example for get_input
to run most of the time, setting it to a larger value would be a practical solution. Of course better if we can fix the random number generator too.
from polytope.
What changes would need to be made to the random number generator?
from polytope.
I meant fixing the seed of the random number generator (see #13).
from polytope.
Related Issues (20)
- cvxopt 1.2.0 bug HOT 5
- support Python 3.7 HOT 4
- create regression test for bug fix of PR #56
- release `polytope == 0.2.2` HOT 1
- Error message says "Cannot plot polytopes of dimension larger than 2", but can't plot dimension 1 aswell HOT 2
- Zero Volume for 14D polytope HOT 8
- remove support for Python 2.7, 3.5, 3.6 HOT 7
- support Python 3.10
- With large scales `reduce` can remove non-redundant hyperplanes HOT 2
- `.project` can return redundant hyperplanes despite `minrep == True` HOT 1
- Plotting polytopes on same plot/ adding "_get_patch" as an import option
- How to use cvxopt to find intersection between polytope HOT 4
- polytope volume changing on each trial HOT 2
- Polytope.reduce and removal of possibly overlapping polytopes HOT 3
- Updated release on PyPI? HOT 4
- Rmove or delete particular polytope from a region HOT 1
- combining many polytopes into single polytope HOT 4
- MIB2 cannot clear 01637 error HOT 3
- minkovski sum of polytopes HOT 5
- Usefull future feature
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from polytope.