Comments (11)
@N-Wouda I implemented the write_instance
and write_solution
functions. Hopefully, they are useful!
from vrplib.
I made a start for writing instances.
- Find the original VRPLIB reference
- Check for inconsistencies across the VRPLIB instances
- Think about the interface: how do we infer from
instance
which attributes should be written?
from vrplib.
See http://www.bernabe.dorronsoro.es/vrp/index.html?/Problem_Instances/VRPLIBDesc.html for the original VRPLIB descrption.
from vrplib.
LKH-3 is very well maintained, so I think it's good to support reading those files as well (perhaps long term but not now?)
from vrplib.
The VRPLIB format consists of a problem specification part and a data part.
- The problem specification indicates the type of the problem. This includes the name, comments, problem type, dimensions, edge weight type, and problem-specific scalar information (e.g., capacity, duration limit, ...).
- The data consists of sections, e.g., coordinates, demands, time windows, etc. For most vehicle routing problems, these are node-related attributes. Each section starts with the section name (e.g.,
DEMAND_SECTION
), then$n$ rows of the corresponding data. - The file ends with
EOF
.
from vrplib.
Both for reading and writing files, we should follow the LKH-3 VRPLIB format.
But the Solomon and GH instances on CVRPLIB do not follow the VRPLIB format. What do I want to do with that? The LKH3 instances do follow the VRPLIB format.
from vrplib.
https://www.sintef.no/projectweb/top/vrptw/100-customers/
LKH-3 calls this "Sintef solution style"
from vrplib.
I have removed the write
module because this wasn't ready yet, and I want to speed up the release of V1. So this is an open issue again.
from vrplib.
See this commit for the (removed) write module 885f9cc#diff-6fa8cb67482a47a8390d40bcd32b10d53f6ffd7a723f412d71a486039267557f.
from vrplib.
This is periodically useful for the PyVRP instances as well (I'm running into this now with multi-depot VRP). Do you want to be really strict about what's written? A simple dict -> specification/section type writer is easy enough: every value that's iterable becomes a section, and every value that's not becomes a specification. The onus would then be on the user to ensure that data encodes a valid VRPLIB instances, but to be fair, that's on the user anyway when they're writing instances.
from vrplib.
Yeah that seems like a good solution to me. I'll try to make this feature later this week.
from vrplib.
Related Issues (20)
- UnicodeDecodeError when reading SINTEF solution file HOT 2
- Raise warning when empty instance/solution
- Line comments HOT 4
- Documentation HOT 4
- Distance Matrix Rounding HOT 4
- Deprecate downloading instances
- Parse non-tabular section data
- Extend VRPLIB format with arc list
- Handle rounding conventions HOT 1
- VRPLIB v2 HOT 1
- Reindex sections based on indices
- Parse large instances with 15K or 30K nodes
- Ordering issue in VRPLIB files
- Check if TSPLIB95 can be read
- Optional distance computation for large instances
- Ignore -1 in depot section HOT 1
- Specify instance and solution formats in README
- Supersede TSPLIB HOT 1
- Prize-collecting and benchmark instances HOT 5
- Validate instance and solution data
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 vrplib.