tensor: use canonicalize_shape in flatten

This commit is contained in:
2025-11-12 14:59:46 +01:00
parent 641b632df1
commit ee3687ac36

View File

@@ -871,8 +871,7 @@ if(is_flat())
if(has_symmetry()) //get rid of formal symemtry
{
Tensor<T> r(*this);
r.shape.copyonwrite();
for(int g=0; g<r.shape.size(); ++g) r.shape[g].symmetry=0;
r.canonicalize_shape();
return r;
}
else