Giter Club home page Giter Club logo

dtld_parsing's People

Contributors

julimueller avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

dtld_parsing's Issues

cannot connect to X server

i am trying to run and load the dataset but get the error: cannot connect to X server. i am running load_dtld.py with the proper path CLAs. i am currently loading only the berlin dataset, and i have changed the path and disp_path in the yaml file to point to the correct image location (based on the output it seems to be correct?). am i missing something?

Opening DriveuDatabase from File: data/dtld/Berlin_all.yml
data/dtld/Berlin/Berlin1/2015-04-17_10-50-05/DE_BBBR667_2015-04-17_10-50-13-633939_k0.tiff
...
Intrinsic Matrix:

[[2.29051e+03 0.00000e+00 1.06694e+03]
 [0.00000e+00 2.29051e+03 4.77152e+02]
 [0.00000e+00 0.00000e+00 1.00000e+00]]

Extrinsic Matrix:

[[ 0.0037 -0.0453  0.999   2.105 ]
 [-0.9998  0.0188  0.0047  0.049 ]
 [-0.0189 -0.9988 -0.0452  0.919 ]]

Projection Matrix:

[[2.26969958e+03 0.00000000e+00 1.05129465e+03 0.00000000e+00]
 [0.00000000e+00 2.26969958e+03 4.58462746e+02 0.00000000e+00]
 [0.00000000e+00 0.00000000e+00 1.00000000e+00 0.00000000e+00]]

Rectification Matrix:

[[ 9.99999e-01 -1.18600e-03  6.77000e-04]
 [ 1.18100e-03  9.99972e-01  7.35600e-03]
 [-6.86000e-04 -7.35500e-03  9.99973e-01]]

Distortion Matrix:

[[-0.036004  0.        0.        0.        0.      ]]

: cannot connect to X server

System

python 3.6
Ubuntu 16.04

Using disparity images/maps to get real distance information

Hello,
Firstly, thank you for your amazing work. I am currently working on DTLD for my thesis. As mentioned in the title, I need to calculate real distance by using disparity images. Finding the depth is straightforward with focal length, baseline, and disparity matrix (considering parallel camera setup). However, I could not figure out how to calculate the 3D location of a point from the depth information. In OpenCV, there is the function cv2.reprojectImageTo3D(disparity_image, Q) where it requires 4x4 Q matrix (projection transformation matrix) and according to documentation, it can be obtained by cv2.stereoRectify(), but this one requires the following:

cameraMatrix1 – First camera matrix.
cameraMatrix2 – Second camera matrix.
distCoeffs1 – First camera distortion parameters.
distCoeffs2 – Second camera distortion parameters.
imageSize – Size of the image used for stereo calibration.
R – Rotation matrix between the coordinate systems of the first and the second cameras.
T – Translation vector between coordinate systems of the cameras.

Checking the calibration data published, I see that I need intrinsic matrix and distortion coefficients for the right camera too.
Could you help me about this task? Thank you very much.

Error with pyyaml 6.0

python3 load_dtld.py --label_file /DriveU/dtld_data/v2.0/DTLD_all.json --calib_dir /DriveU/dtld_parsing/calibration --data_base_dir /DriveU/dtld_data

2021-12-19 17:23:08.352 INFO driveu_dataset - open: Opening DriveuDatabase from file: /DriveU/dtld_data/v2.0/DTLD_all.json Traceback (most recent call last): File "load_dtld.py", line 119, in <module> main(parse_args()) File "load_dtld.py", line 61, in main intrinsic_left = calibration.load_intrinsic_matrix( File "/DriveU/dtld_parsing/python/dtld_parsing/calibration.py", line 262, in load_intrinsic_matrix matrix = self.load_calibration_matrix(path) File "/DriveU/dtld_parsing/python/dtld_parsing/calibration.py", line 249, in load_calibration_matrix data = yaml.load(infile) TypeError: load() missing 1 required positional argument: 'Loader'

class list

hello, I have seen the class annotition about the dataset as the following picture, do you know the class list or all class numbers?
for example: if the first bit of Viewpoint orientation is 2,3,4, apperantly, the behind annotation is none, so the class numbers is not 44745*7
image

.tiff files are black

Hi,

I suspect there is something I'm doing wrong, but in the datasets all the ..._k0.tiff images are black.
Is there something I'm supposed to do to them first so that I can see them?

Thanks.

Are images pre-rectified?

Hi Julian, I'm working on a fork of this repo to convert the dataset to Tensorflow records and had a quick question regarding calibration. Are the RGB (non-stereo) images provided pre-rectified or do we need to do that manually using the intrinsics provided? I don't see much warping in the sample images but I want to make sure that Tensorflow is ingesting properly rectified data.

EDIT: Looking through the python code, it seems that the bounding box coordinates are rectified using opencv but the images themselves are not. Would I be correct in assuming that the bounding boxes are unrectified and the images themselves are rectified? That would be a little counter-intuitive.

Label map for Tensorflow

Hello,

Thank you for your work on parsing the dataset, and also for such a great dataset.

I was wondering how we need to create a label map for training using TensorFlow. TensorFlow requires a label map, which namely maps each of the used labels to an integer values. This label map is used both by the training and detection processes.

An example of it is below, assuming dataset contains three labels:

item {
id: 1
name: 'red'
}

item {
id: 2
name: 'green'
}

item {
id: 3
name: 'yellow'
}

I am bit confused about if we need to put all the labels, given we have a lot of attributes in the dataset or what could be the possible workaround? Any help is much appreciated.

python setup.py install command fails

When trying to run "python setup.py install" it gives me this error:

Traceback (most recent call last):
File "setup.py", line 1, in
from setuptools import setup, find_packages
ImportError: No module named setuptools

Saw that some modules were updated to Python 3.
Shouldn't we use the command "python3 setup.py install" instead in order to run it with python 3?

TypeError: 'NoneType' object does not support item assignment

Hi, i got this problem during visualization of images. I did everything according to instructions:

python3 load_dtld.py --label_file Berlin_all.yml --calib_dir /dtld_parsing-master/calibration --data_base_dir /Berlin/

For some time everything was going well, i think:

2020-04-23 14:15:12.976 INFO load_dtld - main: Intrinsic Matrix:

[[2290.51     0.    1066.94 ]
 [   0.    2290.51   477.152]
 [   0.       0.       1.   ]]

2020-04-23 14:15:12.977 INFO load_dtld - main: Extrinsic Matrix:

[[ 0.0037 -0.0453  0.999   2.105 ]
 [-0.9998  0.0188  0.0047  0.049 ]
 [-0.0189 -0.9988 -0.0452  0.919 ]]

2020-04-23 14:15:12.978 INFO load_dtld - main: Projection Matrix:

[[2269.699585    0.       1051.294655    0.      ]
 [   0.       2269.699585  458.462746    0.      ]
 [   0.          0.          1.          0.      ]]

2020-04-23 14:15:12.979 INFO load_dtld - main: Rectification Matrix:

[[ 0.999999 -0.001186  0.000677]
 [ 0.001181  0.999972  0.007356]
 [-0.000686 -0.007355  0.999973]]

2020-04-23 14:15:12.980 INFO load_dtld - main: Distortion Matrix:

[[-0.036004  0.        0.        0.        0.      ]]

But then i got this error:

Traceback (most recent call last):
  File "load_dtld.py", line 106, in <module>
    main(parse_args())
  File "load_dtld.py", line 76, in main
    img_disp = img.visualize_disparity_image()
  File "/traffic_lights/dtld_parsing-master/python/dtld_parsing/driveu_dataset.py", line 206, in visualize_disparity_image
    img = self.get_disparity_image()
  File "/traffic_lights/dtld_parsing-master/python/dtld_parsing/driveu_dataset.py", line 189, in get_disparity_image
    img[img == 65535] = 0
TypeError: 'NoneType' object does not support item assignment

Do you have any advises for me? Some image didn't find or..?

Display/load image in natural colors

Hello,
I am trying to load the images from this dataset in natural colors. I use the following code:

img_file = str(image_path)
img = cv2.imread(img_file, cv2.IMREAD_UNCHANGED)
img = cv2.cvtColor(img, cv2.COLOR_BAYER_GB2BGR)
img = np.right_shift(img, 4)
img = img.astype(np.uint8)
plt.figure(figsize=(20,20))
plt.imshow(img)

The "image_path" variable contains the path to one image ending with "k0.tiff". Unfortunately, when I display the images there seems to be a different color setting, as you can see in the attached image (yellow colors are showed as bluish).

Thank you for any help!

DriveUImg

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.