Comments (4)
Thank you!
from gym-pybullet-drones.
Have a look at class RLTakeoffAviary
(used in scriptlearn.py
)
The current _computeReward
is a step-wise function of the drone's z in the world frame
You can hard-code a goal position by making _computeReward
return a (dense or sparse) reward computed as a function of the distance from the desired point
Note that
_computeDone
terminates episodes outside the cube with edge=1, on top of the world frame origin (0,0,0)
To fly outside this space, you'd need to re-implement both
_computeDone
and_clipAndNormalizeState
from gym-pybullet-drones.
In my RL problem I'm introducing a design that has tilting motors, where I just mind about the thrust vectoring, not about collision of the propellers (though every visual has a corresponding collision box). I extended the actionspace for two additional values (n=6), made sure to set the upper and lower limits of the joints and I can confirm I can control them by setting a POSITION inside BaseAviary and see correct rotations in fly.py).
0 degree, 0 degree
+30 degree (jointUpperLimit), -30 degree (jointLowerLimit)
+30 degree ,+30 degree
I now wonder how _clipAndNormalizeState
plays a role here. I cannot find any call to this function, not in this repo nor in openai/gym or all github :) .
Do I append my two link positions (both can travel -30 to +30 degrees, set in RAD) that I want the singleAgent to optimize?
Would I modify norm_and_clipped
inside HoverAviary (
computeControl
in SimplePIDController (which I'm using in baseAviary) to include the two angles of the motor joints?from gym-pybullet-drones.
I only briefly read this message (I'm not sure why it's in this issue?).
_clipAndNormalizeState
is called in _computeObs
of BaseSingleAgentAviary.py
(or the multi agent class)
obs = self._clipAndNormalizeState(self._getDroneStateVector(0))
It's just an extra function to clip and normalized the state vector IF a certain RL problem requires it (or can benefit from it).
It can be an identity function if you want to, you probably don't want to clip and normalize if you are using one of the PID controllers.
If you change the state vector, you would want to use computeControl
instead of computeControlFromState
in BaseControl
(one is just a wrapper for the other to use fewer arguments).
from gym-pybullet-drones.
Related Issues (20)
- RPM Motor Mapping HOT 6
- Some camera associated issues HOT 1
- What does pycffirmware do HOT 1
- run learn.py
- rgb and GL HOT 2
- path planning algorithms HOT 1
- Ctrl Freq and Simulation Freq Questions HOT 3
- Clarification on Each Dimension's Meaning for ActionType.VEL HOT 3
- Discrete action space implementation based on BaseRLAviary HOT 1
- Visualize drone cameras in explorer HOT 1
- Location of Paper on Dynamics Code HOT 1
- -1 to 1 action space meaning HOT 1
- Pybullet drones
- No module named 'gym_pybullet_drones.envs.VisionAviary'
- Units HOT 1
- High frequency in RPMs when include action buffer in observation space can couse problems in real hardware HOT 2
- Why might my rewards be inversely proportional to the target height in the HoverAviary environment? HOT 2
- Error while running velocity.py and fly.py examples HOT 1
- ray 1.9 error while installing gym-pybullet-drones HOT 1
- Sim2real transfer for betaflight HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from gym-pybullet-drones.