Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
OpenDAS
OpenPCDet
Commits
963f4f30
Unverified
Commit
963f4f30
authored
Sep 20, 2022
by
agent-sgs
Committed by
GitHub
Sep 20, 2022
Browse files
Fixbug for PillarNet (#1115)
parent
a38a580f
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
36 additions
and
1 deletion
+36
-1
pcdet/models/detectors/__init__.py
pcdet/models/detectors/__init__.py
+2
-1
pcdet/models/detectors/pillarnet.py
pcdet/models/detectors/pillarnet.py
+34
-0
No files found.
pcdet/models/detectors/__init__.py
View file @
963f4f30
...
...
@@ -27,7 +27,8 @@ __all__ = {
'PillarNet'
:
PillarNet
,
'PVRCNNPlusPlus'
:
PVRCNNPlusPlus
,
'MPPNet'
:
MPPNet
,
'MPPNetE2E'
:
MPPNetE2E
'MPPNetE2E'
:
MPPNetE2E
,
'PillarNet'
:
PillarNet
}
...
...
pcdet/models/detectors/pillarnet.py
0 → 100644
View file @
963f4f30
from
.detector3d_template
import
Detector3DTemplate
class
PillarNet
(
Detector3DTemplate
):
def
__init__
(
self
,
model_cfg
,
num_class
,
dataset
):
super
().
__init__
(
model_cfg
=
model_cfg
,
num_class
=
num_class
,
dataset
=
dataset
)
self
.
module_list
=
self
.
build_networks
()
def
forward
(
self
,
batch_dict
):
for
cur_module
in
self
.
module_list
:
batch_dict
=
cur_module
(
batch_dict
)
if
self
.
training
:
loss
,
tb_dict
,
disp_dict
=
self
.
get_training_loss
()
ret_dict
=
{
'loss'
:
loss
}
return
ret_dict
,
tb_dict
,
disp_dict
else
:
pred_dicts
,
recall_dicts
=
self
.
post_processing
(
batch_dict
)
return
pred_dicts
,
recall_dicts
def
get_training_loss
(
self
):
disp_dict
=
{}
loss_rpn
,
tb_dict
=
self
.
dense_head
.
get_loss
()
tb_dict
=
{
'loss_rpn'
:
loss_rpn
.
item
(),
**
tb_dict
}
loss
=
loss_rpn
return
loss
,
tb_dict
,
disp_dict
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment