JeVois
1.20
JeVois Smart Embedded Machine Vision Toolkit
|
Share this page: |
|
|
|
|
|
|
Go to the documentation of this file.
32 void loadpy(std::string
const & pypath);
58 LINFO(
"Loaded " << pypath);
75 bool overlay,
bool idle)
100 PythonWrapper::pyinst().attr(
"report")(boost::python::object(), boost::python::object(), overlay, idle);
113 itsImpl = addSubComponent<jevois::dnn::PostProcessorPythonImpl>(
"pypost");
124 pypost::freeze(doit);
127 itsImpl->freeze(doit);
132 JEVOIS_UNUSED_PARAM(param), std::string
const & newval)
134 if (newval.empty() ==
false) itsImpl->loadpy(newval);
139 { itsImpl->process(outs, preproc); }
144 { itsImpl->report(mod, outimg, helper, overlay, idle); }
friend class Component
Allow Component and DynamicParameter to access our registry data, everyone else is locked out.
void onParamChange(postprocessor::pypost const ¶m, std::string const &newval) override
boost::python::list pyVecToList(std::vector< T > const &v)
Helper to convert std::vector<T> to python list.
boost::python::object & pyinst()
Get the python class pyinst, or throw if construction error occurred (e.g., file not found)
void loadpy(std::string const &pypath)
A component of a model hierarchy.
A raw image as coming from a V4L2 Camera and/or being sent out to a USB Gadget.
void freeze(bool doit) override
Freeze/unfreeze parameters that users should not change while running.
PostProcessorPython(std::string const &instance)
Constructor.
Wrapper around GUIhelper to be used by Python.
Helper class to assist modules in creating graphical and GUI elements.
std::shared_ptr< PostProcessorPythonImpl > itsImpl
void process(std::vector< cv::Mat > const &outs, PreProcessor *preproc)
Pre-Processor for neural network pipeline.
bool hasattr(boost::python::object &o, char const *name)
Check whether a boost::python::object has an attribute.
virtual ~PostProcessorPythonImpl()
void report(jevois::StdModule *mod, jevois::RawImage *outimg=nullptr, jevois::OptGUIhelper *helper=nullptr, bool overlay=true, bool idle=false)
void report(jevois::StdModule *mod, jevois::RawImage *outimg=nullptr, jevois::OptGUIhelper *helper=nullptr, bool overlay=true, bool idle=false) override
Report what happened in last process() to console/output video/GUI.
virtual ~PostProcessorPython()
Destructor.
void process(std::vector< cv::Mat > const &outs, PreProcessor *preproc) override
Process outputs and draw/send some results.
void pythonload(std::string const &path)
Init from path if default constructor was used.
Post-Processor for neural network pipeline.
Helper class to run python code from C++.
std::shared_ptr< PreProcessorForPython > getPreProcForPy() const
Get a pointer to our python-friendly interface.
Base class for a module that supports standardized serial messages.
#define LINFO(msg)
Convenience macro for users to print out console or syslog messages, INFO level.