MCPcopy Create free account
hub / github.com/davisking/dlib / map_from_object

Function map_from_object

tools/python/src/image_dataset_metadata.cpp:97–105  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

95}
96
97std::shared_ptr<std::map<std::string,point>> map_from_object(py::dict obj)
98{
99 auto ret = std::make_shared<std::map<std::string,point>>();
100 for (const auto& v : obj)
101 {
102 (*ret)[v.first.cast<std::string>()] = v.second.cast<point>();
103 }
104 return ret;
105}
106
107// ----------------------------------------------------------------------------------------
108

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected