Skip to content

object has no attribute'allocate_buffers' #23

@CYong030

Description

@CYong030

I met some problem and i can't solve it.

i have two solve direction.
My python have error. My python version is 3.6.9
Cuda doesn't clear completely.

If i get some help, i will appreciate .

`PARAMETERS

  • /rosdistro: melodic
  • /rosversion: 1.14.13
  • /yolov4_trt_node/category_number: 10
  • /yolov4_trt_node/confidence_threshold: 0.5
  • /yolov4_trt_node/input_shape: 416
  • /yolov4_trt_node/model: yolov4
  • /yolov4_trt_node/model_path: /home/jetson/catk...
  • /yolov4_trt_node/show_image: True
  • /yolov4_trt_node/video_topic: /video_source/raw

NODES
/
yolov4_trt_node (yolov4_trt_ros/trt_yolo_v4.py)

auto-starting new master
process[master]: started with pid [15199]
ROS_MASTER_URI=http://localhost:11311

setting /run_id to 291d39c4-29d0-11ed-b07f-60a4b7c96821
process[rosout-1]: started with pid [15212]
started core service [/rosout]
process[yolov4_trt_node-2]: started with pid [15215]
Traceback (most recent call last):
File "/home/jetson/catkin_ws/src/yolov4_trt_ros/trt_yolo_v4.py", line 175, in
main()
File "/home/jetson/catkin_ws/src/yolov4_trt_ros/trt_yolo_v4.py", line 164, in main
yolo = yolov4()
File "/home/jetson/catkin_ws/src/yolov4_trt_ros/trt_yolo_v4.py", line 35, in init
(self.model_path + self.model), (self.h, self.w), self.category_num)
File "/home/jetson/catkin_ws/src/yolov4_trt_ros/utils/yolo_with_plugins.py", line 221, in init
self.inputs, self.outputs, self.bindings, self.stream ,grid_sizes= self.allocate_buffers(self.engine, grid_sizes)
AttributeError: 'TrtYOLO' object has no attribute 'allocate_buffers'

PyCUDA ERROR: The context stack was not empty upon module cleanup.

A context was still active when the context stack was being
cleaned up. At this point in our execution, CUDA may already
have been deinitialized, so there is no way we can finish
cleanly. The program will be aborted now.
Use Context.pop() to avoid this problem.
`

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions