Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixing initialization of self.info #1088

Merged
merged 2 commits into from
Feb 25, 2023

Conversation

sisaha9
Copy link
Contributor

@sisaha9 sisaha9 commented Jan 18, 2023

Fixes #1086

@DocGarbanzo
Copy link
Contributor

@Maximellerbach - can you have a look at this?

@Maximellerbach
Copy link
Contributor

@DocGarbanzo the type of self.info['lidar'] should be a np.array, I'm not sure of the expected behavior when the array is empty ? Are we checking somewhere if the array of point is empty / matches the expected shape the model needs ?

@DocGarbanzo
Copy link
Contributor

@DocGarbanzo the type of self.info['lidar'] should be a np.array, I'm not sure of the expected behavior when the array is empty ? Are we checking somewhere if the array of point is empty / matches the expected shape the model needs ?

Currently the lidar data is not used in any models. For now it's just being recorded into the tub, as it would be returned in the run_threaded method. Here, we would need a native python list, but not an np.array.

@Maximellerbach
Copy link
Contributor

Maximellerbach commented Feb 20, 2023

Currently the lidar data is not used in any models. For now it's just being recorded into the tub, as it would be returned in the run_threaded method. Here, we would need a native python list, but not an np.array.

Maybe I'm missing something, why should it be a python list ? I am currently returning from GymDonkeycar a numpy array, if you confirm it should be a list then I will also change it on this side

@Ezward
Copy link
Contributor

Ezward commented Feb 21, 2023

I think the older drivers return an np.array() and the newer drivers return a python list. I would go with the newer drivers. This is what the new driver puts out:

# (angle, distance, time, scan, index).

@Maximellerbach
Copy link
Contributor

Ok ! I will then align with those.
What does the time and scan values look like ?

@Maximellerbach
Copy link
Contributor

So I think we can merge this @DocGarbanzo

Copy link
Contributor

@DocGarbanzo DocGarbanzo left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @sisaha9

@DocGarbanzo DocGarbanzo merged commit 30f8488 into autorope:main Feb 25, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Unable to use Lidar in DonkeyCar Sim
4 participants