Open matjobst opened 1 year ago
I see your point, but it might also be useful to leave it to keep NIR explicit and expressive. Any other opinions?
(no rush on this, we can resolve this after the initial paper submission)
As long as the graph has an Input with a given shape, the infer_shapes is able to determine the shapes, so I think the same goes as for any other layer, that we do not need to store the input_type. I believe our consensus was that we do not store unnecessary information. But of course, the infer_shapes can and will determine the input_type of the Flatten layer. Therefore I do not think removing the field (I am only talking about the explicit field, not the one set by post_init) does not make NIR less expressive.
The Flatten layer should not have a separate input_type field. It is not necessary. The input shape can be determined from the previous nodes. And every layer anyways has a input_type by inheritance.