DLR-RM / AugmentedAutoencoder

Official Code: Implicit 3D Orientation Learning for 6D Object Detection from RGB Images
MIT License
338 stars 97 forks source link

How to use multiple Autoencoder #66

Closed CaptainTimberTim closed 3 years ago

CaptainTimberTim commented 4 years ago

Hello, since quite a while I try to have more than one object which I want its pose detected. I trained the retina network, which works well. But when I try to use more than one autoencoder like this: /// experiments = ['exp_group2/Septamino_Grey', 'exp_group2/Tetramino', ] ... class_names = [0, 1] /// I get an error as soon as the detector outputs a 1 as a label. The same happens when I switch the autencoder, so it is not the encoder itself that does not work. It must be something else, maybe with loading both AAEs at the beginning? I searched for a solution for quite a while now and have no clue. The other issue I posted is the error message I get, but that seems to only be the symptom but not the cause.

Is there maybe anything basic I am missing to use more than one AAE? In another issue from someone else you said "An example is in the test section" for multiple AAEs, but I cannot find this test section, what was meant by that? @MartinSmeyer

Help would really really be appreciated. You are doing great work! Keep it up

MartinSmeyer commented 4 years ago

Hey! Did you try

python auto_pose/test/aae_retina_webcam_pose.py -test_config aae_retina_webcam.cfg -vis

as described in multi-object-rgb-based-6d-object-detection-from-a-webcam-stream?

It does work with multiple autoencoders for me. What is the thrown error?

CaptainTimberTim commented 4 years ago

I tested it with the python auto_pose/test/aae_retina_webcam_pose.py as well and get the same error.

This is it:

tensorflow/core/framework/op_kernel.cc:1502] OP_REQUIRES failed at conv_ops.cc:477 : Invalid argument: input depth must be evenly divisible by filter depth: 3 vs 512

my test_config file looks like this:

[MODEL]
gpu_memory_fraction = 0.9

[DATA]
color_format = bgr
color_data_type = np.float32
depth_data_type = np.float32
depth_scale = 1000.

[AAE]
experiments = ['exp_group2/Septamino_Lime','exp_group2/Septamino_Grey']
upright = False
topk = 1

[DETECTOR]

detector_model_path = /home/hci/Dokumente/RetinaNet/TrainedInferenceModel_V2_50_LShapes.h5

backbone = resnet50
class_names = [0, 1]
nms_threshold = 0.5
det_threshold = 0.8
max_detections = 4

[CAMERA]
width = 960
height = 720
K_test = [1037.73754882813 ,0.,408.976318359375, 0., 1037.14465332031 ,231.439361572266 ,  0.,   0.,  1.]
camPose = False

[ICP]
icp = False
CaptainTimberTim commented 4 years ago

@MartinSmeyer

MartinSmeyer commented 4 years ago

Sorry, I am currently quite busy. But will have a closer look this weekend.

MartinSmeyer commented 4 years ago

I know it is super late, but I could not replicate your error so it is hard to solve. If anybody else has the problem or even a solution please post it here.