Skip to content

Commit

Permalink
Adjust to new master
Browse files Browse the repository at this point in the history
  • Loading branch information
p-wysocki committed Nov 27, 2024
1 parent b66b0cd commit 73ea6d9
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 9 deletions.
7 changes: 0 additions & 7 deletions src/bindings/python/src/pyopenvino/utils/utils.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -476,13 +476,6 @@ std::shared_ptr<py::function> wrap_pyfunction(py::function f_callback) {
return callback_sp;
}

double get_stream_size(const py::object& model_stream) {
// Returns io.BytesIO stream size in GB
py::object model_stream_buffer = model_stream.attr("getbuffer")();
py::buffer_info info = py::buffer(model_stream_buffer).request();
constexpr auto one_gigabyte = static_cast<int64_t>(1024) * 1024 * 1024;
return static_cast<double>(info.size * info.itemsize) / one_gigabyte;
}
}; // namespace utils
}; // namespace Common

Expand Down
2 changes: 0 additions & 2 deletions src/bindings/python/src/pyopenvino/utils/utils.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -95,8 +95,6 @@ class MemoryBuffer : public std::streambuf {

std::shared_ptr<py::function> wrap_pyfunction(py::function f_callback);

double get_stream_size(const py::object& model_stream);

}; // namespace utils
}; // namespace Common

Expand Down

0 comments on commit 73ea6d9

Please sign in to comment.