isl-org / Open3D-ML

An extension of Open3D to address 3D Machine Learning tasks
Other
1.85k stars 316 forks source link

'ObjectDetection' object has no attribute 'cfg_tb' #354

Closed AJSDow closed 3 years ago

AJSDow commented 3 years ago

Hi All,

I'm trying to run PointPillars with KITTI, and I keep getting the error 'ObjectDetection' object has no attribute 'cfg_tb'. Can anyone see a fix for this? I'll admit I'm new to Linux and not the most established programmer, but I'm imagining that cfg_tb is something to do with tensorboard having looked at the ObjectDetection code?

Also to note, with no changes the network ran for one epoch, but that was isolated and it gave this error again after the epoch was finished. Many thanks in advance!

Environment:

Ubuntu 20.04 Guest inside VirtualBox on a Windows 10 Pro Host Open3D 0.13.0 Tensorflow 2.4.1

Code:

import open3d.ml as _ml3d
import open3d.ml.tf as ml3d
from path import Path

cfg_file = Path('/media/sf_PhD_Work/PP_config.yml')
cfg = _ml3d.utils.Config.load_from_file(cfg_file)

dataset = ml3d.datasets.KITTI(cfg.dataset.pop('dataset_path', None), **cfg.dataset)

model = ml3d.models.PointPillars(**cfg.model)

pipeline = ml3d.pipelines.ObjectDetection(model=model, dataset=dataset,
                      device='gpu', **cfg.pipeline)

pipeline.run_train()

Returns:

INFO - 2021-08-12 16:59:46,933 - object_detection - Logging in file : ./logs/PointPillars_KITTI_tf/log_train_2021-08-12_16:59:46.txt
INFO - 2021-08-12 16:59:46,937 - kitti - Found 3712 pointclouds for training
INFO - 2021-08-12 16:59:46,951 - object_detection - Initializing from scratch.
Traceback (most recent call last):

  File "/home/user/.config/spyder-py3/temp.py", line 18, in <module>
    pipeline.run_train()

  File "/home/user/anaconda3/lib/python3.8/site-packages/open3d/_ml3d/tf/pipelines/object_detection.py", line 226, in run_train
    self.save_config(writer)

  File "/home/user/anaconda3/lib/python3.8/site-packages/open3d/_ml3d/tf/pipelines/object_detection.py", line 318, in save_config
    tf.summary.text("Open3D-ML", self.cfg_tb['readme'], step=0)

AttributeError: 'ObjectDetection' object has no attribute 'cfg_tb'
AJSDow commented 3 years ago

Apologies, found the previous issue that discusses this, not sure why I couldn't find it before. For reference it's found in the comments of Issue #221