From c432996dd55c9dfbc6a57e49e0838f1cf6bdba9f Mon Sep 17 00:00:00 2001 From: Ibai Date: Fri, 8 Apr 2022 20:45:33 +0900 Subject: [PATCH] Set flow_init to optional --- nets/crestereo.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/nets/crestereo.py b/nets/crestereo.py index f6d2a37..3f99917 100644 --- a/nets/crestereo.py +++ b/nets/crestereo.py @@ -81,7 +81,7 @@ class CREStereo(nn.Module): zero_flow = torch.cat((_x, _y), dim=1).to(fmap.device) return zero_flow - def forward(self, image1, image2, flow_init, iters=10, upsample=True, test_mode=False): + def forward(self, image1, image2, flow_init=None, iters=10, upsample=True, test_mode=False): """ Estimate optical flow between pair of frames """ image1 = 2 * (image1 / 255.0) - 1.0