Skip to content

Commit

Permalink
fix tensor rm method bug
Browse files Browse the repository at this point in the history
  • Loading branch information
Neutree committed Aug 7, 2024
1 parent 11af2ff commit ae9435b
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions components/basic/include/maix_tensor.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -491,6 +491,10 @@ namespace maix
*/
void rm_tensor(const std::string &key)
{
if(_auto_delete[key])
{
delete tensors[key];
}
tensors.erase(key);
}

Expand Down

0 comments on commit ae9435b

Please sign in to comment.