ifm / libo3d3xx

Driver and utilities for IFM Efector O3D3xx depth cameras
Apache License 2.0
38 stars 39 forks source link

Random reappearance of noisy behaviour for the same scene #141

Closed robinbansal08 closed 4 years ago

robinbansal08 commented 4 years ago

We have 48 O3D303 cameras installed in a hall of a warehouse at a height of 9.5 meters. All cameras are enabled as software triggered and are managed by a trigger scheduling algorithm to handle any interference issues.

We have noticed that sometimes all the 48 cameras at the same time captures very noisy point cloud of the same scene as compared to other times, when all the cameras provides good point cloud.

--> Here you see the nice point cloud captured by a camera.

cam_16_goodPCD

--> Here you see the noisy point cloud captured by the same camera for same scene the next day.

cam_16_noisyPCD

We did not change any filter configuration and there was no movement in the scene for both cases, still much difference in the level of noise can be observed.

Here is the json file for the camera: cam_ip_16_newswu_dump.txt

GreNait commented 4 years ago

Hi @robinbansal08,

First, could you tell us the firmware version of your units and the general mode? Like, do you use single/double exposure, do you use 1,2 or 3 frequencies? This might help us to verify the problem here.

The images itself are looking familiar to problems like sunlight or cross talk. If two or more cameras are active at the same time, and if their FOV is overlapping a bit, you get that kind of noise. Is the floor and ceiling reflective? We also had some issues, when the light is reflected by the floor to the ceiling and back (I don't expect that in this case, but you never know).

Best regards

graugans commented 4 years ago

Hey @robinbansal08 unrelated to your issue, we do recommend to use https://github.com/ifm/ifm3d for new projects. The libo3d3xx project is not recommended for new projects unless you are planning to integrate code on the camera.

robinbansal08 commented 4 years ago

@graugans Thank you for your reply. Yes, we are using libo3d3xx as we want to integrate our codes on the camera.

@GreNait Thank you for your reply. Here is the dumped configuration file:

{
    "o3d3xx": {
        "libo3d3xx": "705",
        "Date": "Fri Jun 12 15:26:41 2020",
        "HWInfo": {
            "Connector": "#!02_A300_C40_04246016_008023176",
            "Diagnose": "#!02_D322_C34_04250651_008026824",
            "MiraSerial": "8670-81c3-0e63-0794",
            "MACAddress": "00:02:01:41:3B:AE",
            "Frontend": "#!02_F342_C34_19_00105_008023607",
            "Mainboard": "#!02_M381_C41_03901679_008023690",
            "Illumination": "#!02_I300_001_04201465_008001175"
        },
        "SWVersion": {
            "IFM_Software": "1.30.5309",
            "Main_Application": "1.0.44",
            "IFM_Recovery": "unversioned",
            "Algorithm_Version": "2.2.14",
            "Calibration_Device": "00:02:01:41:3b:ae",
            "Calibration_Version": "1.0.2",
            "Linux": "Linux version 3.14.34-rt31-yocto-standard-00048-gc8112a91aeb2-dirty (jenkins@dettlx190) (gcc version 4.9.2 (GCC) ) #1 SMP PREEMPT RT Wed Mar 27 18:25:10 CET 2019",
            "Diagnostic_Controller": "v1.0.44-2dcaabbc73-dirty"
        },
        "Device": {
            "Name": "New sensor",
            "Description": "",
            "ActiveApplication": "1",
            "PcicTcpPort": "50010",
            "PcicProtocolVersion": "3",
            "IOLogicType": "1",
            "IODebouncing": "true",
            "IOExternApplicationSwitch": "0",
            "SessionTimeout": "30",
            "ServiceReportPassedBuffer": "15",
            "ServiceReportFailedBuffer": "15",
            "ExtrinsicCalibTransX": "0",
            "ExtrinsicCalibTransY": "0",
            "ExtrinsicCalibTransZ": "0",
            "ExtrinsicCalibRotX": "0",
            "ExtrinsicCalibRotY": "0",
            "ExtrinsicCalibRotZ": "0",
            "EvaluationFinishedMinHoldTime": "10",
            "SaveRestoreStatsOnApplSwitch": "true",
            "IPAddressConfig": "0",
            "PasswordActivated": "false",
            "OperatingMode": "1",
            "DeviceType": "1:2",
            "ArticleNumber": "O3D303",
            "ArticleStatus": "AD",
            "UpTime": "3.8574999999999999",
            "ImageTimestampReference": "1569337495",
            "TemperatureFront1": "3276.6999999999998",
            "TemperatureFront2": "3276.6999999999998",
            "TemperatureIMX6": "33.009998321533203",
            "TemperatureIllu": "36.799999999999997",
            "PNIODeviceName": "",
            "EthernetFieldBus": "0",
            "EthernetFieldBusEndianness": "0",
            "EnableAcquisitionFinishedPCIC": "false"
        },
        "Net": {
            "MACAddress": "",
            "NetworkSpeed": "0",
            "StaticIPv4Address": "192.168.0.16",
            "StaticIPv4SubNetMask": "255.255.255.0",
            "StaticIPv4Gateway": "192.168.0.201",
            "UseDHCP": "false"
        },
        "Apps": [
            {
                "Name": "Box Detection Application",
                "Description": "",
                "TriggerMode": "2",
                "PcicTcpResultSchema": "{ \"layouter\": \"flexible\", \"format\": { \"dataencoding\": \"ascii\" }, \"elements\": [ { \"type\": \"string\", \"value\": \"star\", \"id\": \"start_string\" }, { \"type\": \"blob\", \"id\": \"normalized_amplitude_image\" }, { \"type\": \"blob\", \"id\": \"distance_image\" }, { \"type\": \"blob\", \"id\": \"x_image\" }, { \"type\": \"blob\", \"id\": \"y_image\" }, { \"type\": \"blob\", \"id\": \"z_image\" }, { \"type\": \"blob\", \"id\": \"confidence_image\" }, { \"type\": \"blob\", \"id\": \"diagnostic_data\" }, { \"type\": \"string\", \"value\": \"stop\", \"id\": \"end_string\" } ] }",
                "PcicEipResultSchema": "{ \"layouter\": \"flexible\", \"format\": { \"dataencoding\": \"binary\", \"order\": \"big\" }, \"elements\" : [ { \"type\": \"string\", \"value\": \"star\", \"id\": \"start_string\" }, { \"type\": \"records\", \"id\": \"models\", \"elements\": [ { \"type\": \"int16\", \"id\": \"boxFound\" }, { \"type\": \"int16\", \"id\": \"width\", \"format\": { \"scale\": 1000 } }, { \"type\": \"int16\", \"id\": \"height\", \"format\": { \"scale\": 1000 } }, { \"type\": \"int16\", \"id\": \"length\", \"format\": { \"scale\": 1000 } }, { \"type\": \"int16\", \"id\": \"xMidTop\", \"format\": { \"scale\": 1000 } }, { \"type\": \"int16\", \"id\": \"yMidTop\", \"format\": { \"scale\": 1000 } }, { \"type\": \"int16\", \"id\": \"zMidTop\", \"format\": { \"scale\": 1000 } }, { \"type\": \"int16\", \"id\": \"yawAngle\" }, { \"type\": \"int16\", \"id\": \"qualityLength\" }, { \"type\": \"int16\", \"id\": \"qualityWidth\" }, { \"type\": \"int16\", \"id\": \"qualityHeight\" } ] }, { \"type\": \"string\", \"value\": \"stop\", \"id\": \"end_string\" } ] }",
                "PcicPnioResultSchema": "{\"layouter\" : \"flexible\", \"format\": { \"dataencoding\": \"binary\", \"order\": \"big\" }, \"elements\" : [ { \"type\": \"string\", \"value\": \"star\", \"id\": \"start_string\" }, { \"type\": \"records\", \"id\": \"models\", \"elements\": [ { \"type\": \"int16\", \"id\": \"boxFound\" }, { \"type\": \"int16\", \"id\": \"width\", \"format\": { \"scale\": 1000 } }, { \"type\": \"int16\", \"id\": \"height\", \"format\": { \"scale\": 1000 } }, { \"type\": \"int16\", \"id\": \"length\", \"format\": { \"scale\": 1000 } }, { \"type\": \"int16\", \"id\": \"xMidTop\", \"format\": { \"scale\": 1000 } }, { \"type\": \"int16\", \"id\": \"yMidTop\", \"format\": { \"scale\": 1000 } }, { \"type\": \"int16\", \"id\": \"zMidTop\", \"format\": { \"scale\": 1000 } }, { \"type\": \"int16\", \"id\": \"yawAngle\" }, { \"type\": \"int16\", \"id\": \"qualityLength\" }, { \"type\": \"int16\", \"id\": \"qualityWidth\" }, { \"type\": \"int16\", \"id\": \"qualityHeight\" } ] }, { \"type\": \"string\", \"value\": \"stop\", \"id\": \"end_string\" } ] }",
                "LogicGraph": "{\"IOMap\": {\"OUT1\": \"RFT\",\"OUT2\": \"AQUFIN\"},\"blocks\": {\"B00001\": {\"pos\": {\"x\": 200,\"y\": 200},\"properties\": {},\"type\": \"PIN_EVENT_IMAGE_ACQUISITION_FINISHED\"},\"B00002\": {\"pos\": {\"x\": 200,\"y\": 75},\"properties\": {},\"type\": \"PIN_EVENT_READY_FOR_TRIGGER\"},\"B00003\": {\"pos\": {\"x\": 600,\"y\": 75},\"properties\": {\"pulse_duration\": 0},\"type\": \"DIGITAL_OUT1\"},\"B00005\": {\"pos\": {\"x\": 600,\"y\": 200},\"properties\": {\"pulse_duration\": 0},\"type\": \"DIGITAL_OUT2\"}},\"connectors\": {\"C00000\": {\"dst\": \"B00003\",\"dstEP\": 0,\"src\": \"B00002\",\"srcEP\": 0},\"C00001\": {\"dst\": \"B00005\",\"dstEP\": 0,\"src\": \"B00001\",\"srcEP\": 0}}}",
                "Type": "Camera",
                "Index": "1",
                "Id": "476707713",
                "Imager": {
                    "AutoExposureReferencePointX": "88",
                    "AutoExposureReferencePointY": "66",
                    "AutoExposureReferenceType": "0",
                    "AutoExposureMaxExposureTime": "10000",
                    "AutoExposureReferenceROI": "{\"ROIs\":[{\"id\":0,\"group\":0,\"type\":\"Rect\",\"width\":130,\"height\":100,\"angle\":0,\"center_x\":88,\"center_y\":66}]}",
                    "Channel": "0",
                    "ClippingBottom": "263",
                    "ClippingLeft": "0",
                    "ClippingRight": "351",
                    "ClippingTop": "0",
                    "ContinuousAutoExposure": "false",
                    "EnableAmplitudeCorrection": "true",
                    "EnableFastFrequency": "false",
                    "EnableFilterAmplitudeImage": "false",
                    "EnableFilterDistanceImage": "true",
                    "EnableRectificationAmplitudeImage": "false",
                    "EnableRectificationDistanceImage": "false",
                    "UseSimpleBinning": "false",
                    "ExposureTime": "10000",
                    "ExposureTimeList": "2500;10000",
                    "ExposureTimeRatio": "4",
                    "FrameRate": "5",
                    "MinimumAmplitude": "2",
                    "Resolution": "1",
                    "ClippingCuboid": "{\"XMin\": -3.402823e+38, \"XMax\": 3.402823e+38, \"YMin\": -3.402823e+38, \"YMax\": 3.402823e+38, \"ZMin\": -3.402823e+38, \"ZMax\": 3.402823e+38}",
                    "SpatialFilterType": "1",
                    "SymmetryThreshold": "0",
                    "TemporalFilterType": "0",
                    "ThreeFreqMax2FLineDistPercentage": "80",
                    "ThreeFreqMax3FLineDistPercentage": "80",
                    "TwoFreqMaxLineDistPercentage": "80",
                    "Type": "upto30m_moderate",
                    "MaxAllowedLEDFrameRate": "4.9000000000000004",
                    "SpatialFilter": {
                        "Type": "1",
                        "TypeStr_": "Median Filter",
                        "MaskSize": "1",
                        "MaskSizeStr_": "5x5"
                    },
                    "TemporalFilter": {
                        "Type": "0",
                        "TypeStr_": "Off"
                    }
                }
            }
        ]
    }
}

The cameras are configured with upto30m_moderate mode. The cameras are installed at a height of 9.5 meters, inclined 10 degrees from the vertical.

There are no interference issues as we already have scheduled the camera software trigger using a central camera scheduling algorithm such that no two cameras (having common FOV) triggers at the same time.

The warehouse, where the cameras are installed, is constructed such that sunlight enters through parts of the ceiling made of translucent glass pane (about 2m wide) at approx 13m from the floor. The floor is reflective. We realised that this noise is observed mainly during the afternoon. So it turns out that this is definitely a result of interference due to sunlight reflecting from the floor. It would be great if you could suggest any changes that we can do to our cameras (position change not possible) in order to circumvent this problem.

GreNait commented 4 years ago

Well, if it is really sunlight, you can not do anything else than play with the exposure time and use filters. A median filter might already "smoothen" the image. Perhaps, you can also filter over time. Both filters are available within our system. But I am sure, that you can figure out such filters by yourself too.

I have one other guess. Can you check your power supply and the cable length? We had some issues, that if the power supply is to low, but not low enough to be recognized by our system, that sometimes the image gets very noisy. This happens, if e.g. the camera is triggered and a peak is going through the powerline.

Be aware, that you need at least 2A and 24V for every camera. With cable length more than 12m, you need to be certain that still the 24V are arriving at the camera.

Hope this helps.