How to use OptaPlanner - optaplanner

I am new to this thing and want to use Opta Planner in my project to Solve Vehicle Routing Problem. Can anyone guide me step by step how to use it, it would be great.
Thanks

In the current version (7.7) the docs have a quick start that explains the concepts on another use case and then see the VRP implementation example.
For a future version, we intend to make implementing/modeling VRP even simpler by supporting a Vehicle.visitList style model.

Related

OptaPlanner - Create a good, initial solution by hand

Is there a way to create an initial solution for OptaPlanner by hand, in Java code?
I know that I can write the constructionHeuristic in the config XML to create a good initial solution.
But if I can write a better initial solution than OptaPlanner founds, is there a way to start the planning from my solution?
Thanks,
Vilmos
There are several ways of giving OptaPlanner a custom solution:
You can generate any Solution you like ahead of time. If the solution you give to solver.solve(solution) is already initialized at the time, you do not need to call construction heuristics at all.
If you instead wish to take an uninitialized solution and initialize it yourself in OptaPlanner, look into CustomPhaseCommand. Several OptaPlanner examples use that technique, see Machine Reassignment as an example. (However, beware that this is not a public API and we therefore do not guarantee its long-term stability.)

Confusion between mobx-state-tree and mobx-keystone. When to use which?

Both recommended in the official Mobx page if one wants an opinionated way to using mobx for state management.
Based on these(1,2), keystone seems like an improvement of state-tree. Having everything that state-tree has + more. Nowhere I could find anything that state-tree has that keystone doesn't.
I see keystone is nowhere nearly as mature as state-tree. That's probably the main point stopping me from picking it instead. What are other good points for state-tree over keystone?
P.S. It's going to be used in a React app.
I'm the current maintainer of MobX-State-Tree. I think the primary benefit of MST over MobX-Keystone is that MST is used more widely and has more broad third-party support. For example, mobx-devtools supports MST but not MobX-Keystone, as does Reactotron.
With all that said, I'm very interested in exploring MobX-Keystone for our own usage at my consulting company. Even though I'm maintaining MST, I'm not opposed to MobX-Keystone, and the much better TypeScript support is very tempting. If we end up using it in a project and it goes well, we will likely build in support to Reactotron for it.
I hope this perspective helps.
(With regard to the other answer asking if you really need more than just MobX, it's my opinion that MST and MobX-Keystone bring super useful patterns and tools that help you scale across a whole application in a more cohesive way than remaking them yourself using MobX.)
First ask yourself if you really need those libraries, because you can get really far with just mobx and good ol' OOP patterns. In the official docs you have an example of a store that does auto-saving and serializing.
Having said that, I would go for the mobx-keystone. Typescript works right out of the box, and you can use classes to construct your store, which is IMHO, easier that MST stores. Plus the author is very responsive and he is also a contributor to mobx library.
mobx-keystone is super awesome. After using both of the two libraries for a while I would recommend using it over mobx-state-tree in every possible occasions. It's much more intuitive and easer to learn. It saved a lot of time for my project (switching from zustand to jotai to mobx-keystone, IMO each next one is a bit better than previous one in my use case)
After extensive testing / reading the source code / playing with test suite it feels that mobx-keystone provides a more robust developer experience with Typescript and also has enough escape hatches if you need to work with performance sensitive code. I would implementing a small problem (but complex enough) problem with both libraries to judge for yourself.

Pyomo Stochastic Optimization for Vehicle Routing Problem

I'm trying to use the framework Pyomo in order to solve an VRP with stochastic demands. I was wondering if there is some simple examples of VRP in order to get a start point to solve it.
Any help is welcomed!
Thanks a lot in advance!
Though my answer is late, it's better late than none.
Please visit my github page link! and download the example you want.
It's similar to the ReferenceModel.py link sent earlier but that was written seven years ago and there has not been a modification to it. So I have modified it to run with the current version of pyomo.
Hope you will find it helpful

jqgrid with turbogears 2

I have been recently trying out crudRESTController in TG2.1.
Overall, I found that--
1] The community is helpful.
2] But, it is hard to find a help topic or docs, if I get stuck-up with a particular issue.
e.g. The name of instance of crudRESTController must be a plural of underlying model name.
Otherwise, it won't work correctly. It is nowhere given in their docs.
Hence I am thinking to use jqgrid for crud functionality.
Can anybody please point out whether it would be better to use jqgrid or stick to crudRESTController!
(keeping in mind the control I can have over the code, rapid application development, deployment, speed, etc.
Thanks in advance,
Vineet.
Give a look at EasyCrudRestController from tgext.crud, it provides an easy way to create working Crud Controllers on the fly. For more deep customization you can tune it as you would with CrudRestController.

Lucene.Net and Geosearch - is it outthere somewhere?

I've found an interesting article about Lucene and geosearching:
http://sujitpal.blogspot.com/2008/02/spatial-search-with-lucene.html
Is there an equivilant .NET implementation out there that I have been unable to find or do I have to rework the Java-code in his example to fit in the .NET Framework?
I came across this article, as well. I do not see a .NET-specific in my Googling, so I am planning on probably porting this code when the need arises, as well. Right now, I am just getting my feet wet with Lucene.NET and have not gotten to the point that I am comfortable enough with it to start extending it, yet.
The code in the article appears to be a derived example of the conceptual geo-distance functionality outlined in Lucene In Action. Although the book is based on the Java product, it is a great read. The samples port easily and it is full of information.
in the latest lucene.net contrib folder there is spatial contribution to perform geosearch see
https://svn.apache.org/repos/asf/incubator/lucene.net/tags/Lucene.Net_2_9_1/contrib/Spatial.Net/
With Lucene.NET 3.0.3, soon to be released, there is a brand new spatial contrib. See:
http://www.code972.com/blog/2012/05/the-future-of-geo-spatial-searches-with-lucene/
There is worked example at https://www.leapinggorilla.com/Blog/Read/1010/spatial-search-in-lucenenet---worked-example
Regards
Ismail