Skip to content

Commit 644b59d

Browse files
committed
modify the class name for NavDP
1 parent 8dfe9b5 commit 644b59d

2 files changed

Lines changed: 8 additions & 10 deletions

File tree

internnav/model/basemodel/navdp/navdp_policy.py

Lines changed: 5 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -7,15 +7,13 @@
77

88
from internnav.configs.model.base_encoders import ModelCfg
99
from internnav.configs.trainer.exp import ExpCfg
10-
from internnav.model.encoder.navdp_backbone import LearnablePositionalEncoding
1110
from internnav.model.encoder.navdp_backbone import (
12-
NavDP_ImageGoal_Backbone as ImageGoal_Backbone,
11+
ImageGoal_Backbone,
12+
LearnablePositionalEncoding,
13+
PixelGoal_Backbone,
14+
RGBD_Backbone,
15+
SinusoidalPosEmb,
1316
)
14-
from internnav.model.encoder.navdp_backbone import (
15-
NavDP_PixelGoal_Backbone as PixelGoal_Backbone,
16-
)
17-
from internnav.model.encoder.navdp_backbone import NavDP_RGBD_Backbone as RGBD_Backbone
18-
from internnav.model.encoder.navdp_backbone import SinusoidalPosEmb
1917

2018

2119
class NavDPModelConfig(PretrainedConfig):

internnav/model/encoder/navdp_backbone.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -202,7 +202,7 @@ def forward(self, images, depths):
202202
return memory_token
203203

204204

205-
class NavDP_RGBD_Backbone(nn.Module):
205+
class RGBD_Backbone(nn.Module):
206206
def __init__(
207207
self,
208208
image_size=224,
@@ -313,7 +313,7 @@ def _get_device(self):
313313
return torch.device("cuda" if torch.cuda.is_available() else "cpu")
314314

315315

316-
class NavDP_ImageGoal_Backbone(nn.Module):
316+
class ImageGoal_Backbone(nn.Module):
317317
def __init__(self, image_size=224, embed_size=512, device='cuda:0'):
318318
super().__init__()
319319
if device is None:
@@ -376,7 +376,7 @@ def _get_device(self):
376376
return torch.device("cuda" if torch.cuda.is_available() else "cpu")
377377

378378

379-
class NavDP_PixelGoal_Backbone(nn.Module):
379+
class PixelGoal_Backbone(nn.Module):
380380
def __init__(self, image_size=224, embed_size=512, pixel_channel=7, device='cuda:0'):
381381
super().__init__()
382382
if device is None:

0 commit comments

Comments
 (0)