Has there been any it interest to support the or tools API in Go ?
EDIT:
Current implementation:
ToDo List:
It is currently not planned for he foreseeable future but since SWIG seems to support GO feel free to send us a PR for the support...
Hi, for anyone trying to go down this route. I started implementing a port of the java cp sat wrapper for go here. But we have decided to go java instead. For anyone that wants to complete the task you might want to pickup the work I started. I had branched from v7.0 tag.
https://github.com/google/or-tools/compare/v7.0...kchan628:go-wrapper
See the makefiles/Makefile.go.mk as a starting point. It currently only supports Mac
make third_party
make go
make test_go
See wrapper code at /go/sat
Hi,
very nice.
Can you change the CL such that generated go code is in ortools/gen/go/ or
ortools/gen/ortools/go
Laurent Perron | Operations Research | [email protected] | (33) 1 42 68 53
00
*De : *kchan628 notifications@github.com
*Date : *lun. 13 mai 2019 Ã 18:22
*À : *google/or-tools
*Cc : *Subscribed
Hi, for anyone trying to go down this route. I started implementing a port
of the java cp sat wrapper for go here. But we have decided to go java
instead. For anyone that wants to complete the task you might want to
pickup the work I started. I had branched from v7.0 tag.v7.0...kchan628:go-wrapper
https://github.com/google/or-tools/compare/v7.0...kchan628:go-wrapperSee the makefiles/Makefile.go.mk as a starting point. It currently only
supports Macmake third_party
make go
make test_goSee wrapper code at /go/sat
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
https://github.com/google/or-tools/issues/953?email_source=notifications&email_token=ACUPL3PUH2M3IPJ7ZYFXSBLPVGIT7A5CNFSM4GHKMEZKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGODVI2UEI#issuecomment-491891217,
or mute the thread
https://github.com/notifications/unsubscribe-auth/ACUPL3NQQNYCCPTFDHVBTVDPVGIT7ANCNFSM4GHKMEZA
.
hi @lperron I'm not planning to do any more dev work on the go wrapper at the moment. But that seems like a small change to make if somebody wants to continue it.
Agreed. Unfortunately, I have no bandwidth to work on this.
Would the OR tools authors like to include Go bindings in the official repo? I created a small project with SWIG bindings and a handwritten layer on top of the SWIG bindings here: https://github.com/gonzojive/or-tools-go. The bindings are quite limited now - only the linear solver.
The repo builds with Bazel, which was easier than dealing with make and friends for me. I don't have the bandwidth to add support for other build systems.
I would prefer to merge the project into the official repo so it can be tested continuously and not subject to as much bitrot, but of course it's up to the authors. Any suggestions about how to organize the code for a pull request would be appreciated.
Out of curiosity: I see that this was added on the v7.8 milestone. Can you please leave a comment with a small update regarding the go wrapper or if it in your future plans? Thank you. (Decided not to open a feat request since it would be clearly a duplicate of this)
I continued on where @kchan628 left off (thanks!):
master...keenanwl:add-go-wrapper
I also converted some of the Java examples into go test files, like the sudoku sat
In order to keep go.mod happy, I didn't move the generated files to ortools/gen/ortools/go as @lperron requested, but there may still be an idiomatic go way to get that done.
There is still some work needed to clean up a bit, fix the comments and add support for the knapsack solver, and any others I missed.
Otherwise:
make third_party
make go
make test_go
Actually, is it possible to generate the files in
ortools/gen/ortools/sat/go (for the sat part) and still be able to import
as ortools.sat.go ?
This is very nice.
Laurent Perron | Operations Research | [email protected] | (33) 1 42 68 53
00
Le mar. 22 sept. 2020 à 21:29, keenanwl notifications@github.com a écrit :
I continued on where @kchan628 https://github.com/kchan628 left off
(thanks!):master...keenanwl:add-go-wrapper
https://github.com/google/or-tools/compare/master...keenanwl:add-go-wrapperI also converted some of the Java examples into go test files, like the sudoku
sat
https://github.com/keenanwl/or-tools/blob/add-go-wrapper/ortools/go/sat/cp_solver_test.go#L148In order to keep go.mod happy, I didn't move the generated files to
ortools/gen/ortools/go as @lperron https://github.com/lperron
requested, but there may still be an idiomatic go way to get that done.There is still some work needed to clean up a bit, fix the comments and
add support for the knapsack solver, and any others I missed.Otherwise:
make third_party
make go
make test_go—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
https://github.com/google/or-tools/issues/953#issuecomment-696932836,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/ACUPL3MSDOEVJMLMX3Z7Y73SHD3KLANCNFSM4GHKMEZA
.
Added a list at top with forks having some go stuff..., hope to work on it once release 8.0 is out
@lperron yes, that should be possible. I'll take a look at it tomorrow and see what I come up with.
Hopefully it is alright that I went with ortools/gen/ortools/go/sat (08a7fface34b4738a1cb275d60f40c19760d5693), there were some go specific build issues with ortools/gen/ortools/sat and ortools/gen/ortools/sat/go. But I am happy to look at it again if that still doesn't work for you @lperron .
Otherwise I'll just keep going down the list I made of outstanding issues.