What is the input shape? i.e. channels and im_size? I get no error using following
def main():

	m = Discriminator([3, 3, 3, 3], 0.2) #input_channel = 3 and img_size=256

	x = torch.ones((50, 3, 256, 256))
	y = torch.ones((50, 1))
	
	p = m(x)

	obj = nn.BCELoss()

	loss = obj(p, y)