MCPcopy Create free account
hub / github.com/activeloopai/deeplake / write_container

Function write_container

cpp/nd/impl/serialize.hpp:29–36  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

27
28template <typename C>
29inline void write_container(std::ostream& s, const C& c)
30{
31 using V = typename C::value_type;
32 static_assert(std::is_standard_layout_v<V> && std::is_trivial_v<V>);
33 write_pod(s, nd::dtype_enum_v<V>);
34 write_pod(s, c.size());
35 s.write(reinterpret_cast<const char*>(c.data()), c.size() * sizeof(V));
36}
37
38template <typename F>
39inline auto read_vector(std::istream& s, F f)

Callers

nothing calls this directly

Calls 4

write_podFunction · 0.85
sizeMethod · 0.45
writeMethod · 0.45
dataMethod · 0.45

Tested by

no test coverage detected