Comments (6)
i tried with version 0.0.5, now it looks more "artistic" :) but the spring-behaviour is still there, i dont know how to get rid off it. Also the physics are strange, or?
Here is a gif https://github.com/flobotics/custom_ros2_documentation/blob/main/images/google-brax/crawler5-2.gif of this code https://github.com/flobotics/brax/blob/custom_envs_0.0.5/brax/envs/crawler5.py
from brax.
That is a very cool creature you have built :-)
re: "strange" physics, the moment/axis of rotation might seem a bit off, as the large box is flipping around when the small arm actuates. To make this movement look more realistic, you might want to try lowering the mass of the small arms compared to the large box (I noticed they are all 1.0 right now)
Also keep in mind that the system ignores collisions between parent and child joints, so where you are seeing some interpenetration right now, it is probably better to limit the joint angles than to rely on primitives. I'm not seeing any issues with the joint angles in that gif, but if you think there is a problem, please do open a separate issue with a reproable use case.
re: springy joints, yes this is on our roadmap to address. We are looking into techniques such as soft constraints: https://box2d.org/files/ErinCatto_SoftConstraints_GDC2011.pdf
In the mean time you can try increasing the stiffness of the joint, but if you raise it too high the system will explode. This can be mitigated by playing with damping/num physics substeps.
from brax.
hmm, thats frustrating. I set the masses to the real values, e.g. a servo weights 54grams, so i set mass: 0.054 and so on.
But now with this code ( https://github.com/flobotics/brax/blob/custom_envs_0.0.5/brax/envs/crawler5.py ) it only produces a grey-image after training ?
Also the training does not show anything in the chart output, so i think it is going NaN ?
I tried again alot of different settings, remembers me to #44
Also i need to_tf_model which does not work, i tried it again here #25
What do i wrong ? The creature wants to go on a walk :)
thanks for your help
from brax.
The nans are indeed an example of the system 'exploding' mentioned above. The current numerical integrator is not unconditionally stable; that is, with the wrong parameters, this kind of thing is going to happen. It will require tuning to find stable and otherwise acceptable values.
from brax.
i made it "working" , but looks strange. If my creature could do this, it would be great :)
The stiffness of the first joint seemed "strong" , but of the next they move, which they should not.
The other joints rotate more than they should -90/+90. You can see it at the end.
Here is a gif https://github.com/flobotics/custom_ros2_documentation/blob/main/images/google-brax/crawler5-3.gif
and the same as a video https://github.com/flobotics/custom_ros2_documentation/blob/main/images/google-brax/crawler5-3.mp4 todo start,stop,etc. to see it better than the gif.
It would be nice to have the #45 early :) ,as if you need to play with dt and substeps, the training time increases. If you decrease num_timesteps and episode_length, you got a extreme short video which does not show you whats going on.
from brax.
Closing this issue, but feel free to reach out with any new problems.
from brax.
Related Issues (20)
- gradient on trajectory vs sum of gradients on 1 step transitions. HOT 1
- Reacher Task and AutoResetWrapper HOT 1
- Programatic Action Specifications HOT 1
- Subsume part of System inside State; EDIT: Or add Options to reset HOT 11
- MjxEnv no where to be found HOT 2
- Broken links on Github's brax's main page HOT 2
- [MJX] Model loading errors in `brax.io`, for features supported by MJX HOT 1
- Rendering an image with brax.io.image HOT 6
- Dump to json fails if mj model contains no meshes HOT 2
- Collision of robot with solid object HOT 1
- How to access parameter values for each time-step with callback function policy_param? HOT 1
- Different behavior from gym.Mujoco: the walker body penetrate the ground HOT 1
- ValueError: vmap got inconsistent sizes for array axes to be mapped HOT 1
- There's another issue. The renderings are not in color. Here are some example gifs and the code used to produce them. HOT 1
- episode reward is NAN by training HOT 2
- HTML rendering not working in local Jupyter Notebook HOT 2
- Failure to write videos upon training completion HOT 1
- Are control actions scaled in BRAX environments? HOT 6
- Nan encounted in pipeline_step() HOT 1
- Cannot run simple MJX example on standard v4-8 Cloud TPU VM 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 brax.