| 187 | } |
| 188 | |
| 189 | void DeleteOpAndArrays(Model* model, const Operator* op) { |
| 190 | for (const string& array_name : op->inputs) { |
| 191 | DeleteArrayIfUnusedOutsideOfOp(array_name, op, model); |
| 192 | } |
| 193 | for (const string& array_name : op->outputs) { |
| 194 | DeleteArrayIfUnusedOutsideOfOp(array_name, op, model); |
| 195 | } |
| 196 | auto op_it = FindOp(*model, op); |
| 197 | CHECK(op_it != model->operators.end()); |
| 198 | model->operators.erase(op_it); |
| 199 | } |
| 200 | |
| 201 | std::vector<std::unique_ptr<Operator>>::const_iterator FindOpWithOutput( |
| 202 | const Model& model, const string& array_name) { |
no test coverage detected