MCPcopy Create free account
hub / github.com/PyVRP/PyVRP / demands

Method demands

pyvrp/read.py:198–204  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

196 return self.round_func(self.instance["backhaul"])
197
198 def demands(self) -> np.ndarray:
199 if "demand" not in self.instance and "linehaul" not in self.instance:
200 return np.zeros((self.num_locations, 1), dtype=np.int64)
201
202 return self.round_func(
203 self.instance.get("demand", self.instance.get("linehaul"))
204 )
205
206 def coords(self) -> np.ndarray:
207 if "node_coord" not in self.instance:

Callers 2

_clientsMethod · 0.80
_distance_matricesMethod · 0.80

Calls 1

getMethod · 0.80

Tested by

no test coverage detected