Function morpheus::utilities::cast_from_pyobject(const pybind11::object&)
Defined in File json_types.hpp
-
json_t morpheus::utilities::cast_from_pyobject(const pybind11::object &source)
Convert a pybind11 object to a json_t object. The difference to
mrc::pymrc::cast_from_pyobject
is that if the object cannot be serialized, it wraps the python object in aPythonByteContainer
and returns it as a binary.- Parameters
source – : pybind11 object
- Returns
json_t object.