Skip to content

Commit e3c6814

Browse files
committed
Added data (yaml) to repo
1 parent 83befbe commit e3c6814

File tree

3 files changed

+17
-16
lines changed

3 files changed

+17
-16
lines changed

README.md

+13-12
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,14 @@
11
# Intro
22

3-
Intro .
4-
Currently working on pypi
3+
Early release of the simulator simple-playgrounds
54

6-
# Install
5+
First tutorial:
6+
7+
[![Open In Colab](https://colab.research.google.com/assets/colab-badge.svg)]( https://colab.research.google.com/github/mgarciaortiz/simple_playgrounds/blob/master/tutorials/test.ipynb)
78

8-
(sudo) pip install -e /path/to/package
9+
# Install
910

10-
# Tutorials
11+
pip3 install simple-playgrounds
1112

1213
# Coordinates, shapes of environments
1314

@@ -18,18 +19,18 @@ Carthesian coordinate system:
1819

1920

2021
Environment:
21-
- room shape and size: [width, length]
22+
- size: [width, length]
2223
- width along x axis, length along y axis
2324

2425
Entities:
25-
- coordinates x, y
26-
- orientation phi
26+
- position x, y, phi
27+
- phi orientation
2728
- length along axis of phi = 0
2829
- width perpendicular to axis phi = 0
2930

30-
Todo: add drawing to summarize coordinate system
31+
Examples:
3132

32-
tuto:
33+
[Building a playground](https://github.com/mgarciaortiz/simple-playgrounds/blob/master/simple_playgrounds/playgrounds/collection/test/test_scene_elements.py)
34+
35+
[Building an agent and adding sensors](https://github.com/mgarciaortiz/simple-playgrounds/blob/master/tests/test_sensors.py)
3336

34-
markdown
35-
[![Open In Colab](https://colab.research.google.com/assets/colab-badge.svg)]( https://colab.research.google.com/github/mgarciaortiz/simple_playgrounds/blob/master/tutorials/test.ipynb)

setup.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
setup(
44
name='simple_playgrounds',
5-
version='0.9.12',
5+
version='0.9.13',
66
description='Simulator for AGI and RL',
77
author='Michael Garcia Ortiz',
88
author_email='[email protected]',

simple_playgrounds/entities/agents/sensors/sensor.py

+3-3
Original file line numberDiff line numberDiff line change
@@ -111,7 +111,7 @@ def compute_noise(self):
111111
noise = numpy.random.binomial(1, proba, self.shape[0]).reshape((self.shape[0], 1))
112112

113113
else:
114-
noise = numpy.random.binomial(1, proba, (self.shape[0], self.shape[1]))
114+
noise = numpy.random.binomial(1, proba, (self.shape[0], self.shape[1], 1))
115115

116116
self.noise_application_type = 'multiplicative'
117117

@@ -131,10 +131,10 @@ def update_sensor(self, *args, **kwargs):
131131
self.compute_noise()
132132

133133
if self.noise_application_type == 'multiplicative':
134-
self.sensor_value = self.sensor_value * self.noise
134+
self.sensor_value = numpy.multiply(self.sensor_value, self.noise)
135135

136136
else:
137-
self.sensor_value = self.sensor_value + self.noise
137+
self.sensor_value = numpy.add(self.sensor_value, self.noise)
138138

139139
self.sensor_value.clip(0, self._value_range)
140140

0 commit comments

Comments
 (0)