Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Too many indices! #134

Open
AntoinePrv opened this issue Feb 23, 2021 · 0 comments
Open

Too many indices! #134

AntoinePrv opened this issue Feb 23, 2021 · 0 comments
Labels
type/enhancement 🚀 New feature or request

Comments

@AntoinePrv
Copy link
Member

Describe the problem or improvement suggested

There are too many indices in Ecole, which is confusing at best, but most likely error prone.

  • NodeBipartite columns observation are indexed by the LP position of columns;
  • Khalil2016 are ordered by whatever PseudoBranchCands variables order is
  • Branching action set maps the order of PseudoBranchCands OR LPBranchCands variables to the LP position.
  • Branching action is to be an index of LP position

I find this all very confusing, and I spend quite some time on that code, actually I'm reading it right now.
The indices and ordering is also global, so one cannot safely make changes somewhere without risking breaking everything.
Furthermore, it is not possible to use Khalil2016 and Branching with LPBranchCands because we cannot recover that index.

This will only grow more complicated as we add observations/environments.

Describe the solution you would like

The ordering of variables or column should be self contained.

  • Observations should return an additional vector that tell for every line the SCIP_VAR* for the features;
  • Branching environment should only accept a SCIP_VAR*, no indices involved;
  • Branching action_set would need to become a vector of SCIP_VAR*, which NodeBipartite users would need to pass through numpy.argwhere to get the indices they had before.

Describe alternatives you have considered

Additional context

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type/enhancement 🚀 New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant