Commit 057e3d9c authored by pbethge's avatar pbethge
Browse files

fix runMultiModel

parent 44de48e2
1.2.2: 2022 Feb 21
* update cppflow
* add support for frozen graphs
* add basic frozen graph example
* fix ofxTF2::Model::runMultiModel() more less inputs than initially named
1.2.1: 2022 Feb 16
* fixed incorrect changelog version
......
......@@ -94,8 +94,14 @@ Model::runMultiModel(const std::vector<cppflow::tensor> & inputs) const {
using inputTuple_t = std::tuple<std::string, cppflow::tensor>;
std::vector<inputTuple_t> inputArguments;
if (inputs.size() > inputNames_.size()) {
ofLogError("ofxTensorFlow2") << "Model: number of inputs greater than "
<< "number of input names";
return std::vector<cppflow::tensor>(-1);
}
// add the names from settings and tensors to the vector of arguments
for(unsigned int i = 0; i < inputNames_.size(); i++) {
for(unsigned int i = 0; i < inputs.size(); i++) {
inputArguments.push_back(inputTuple_t(inputNames_[i], inputs[i]));
}
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment