Input shape refers to the shape of your input tensor(s), which you are passing to your model.
E.g. nn.Conv2d modules expect a 4-dimensional tensor with the shape [batch_size, channels, height, width].
Could you remove unrelated code snippets (e.g. the opencv cascade etc.) and post a (minimal) code snippet to reproduce your error using random input data, please?
PS: You can add code snippets by wrapping them in three backticks ```