danfoa / morphosymm Goto Github PK
View Code? Open in Web Editor NEWTools for exploiting Morphological Symmetries in robotics
Home Page: https://danfoa.github.io/MorphoSymm/
License: MIT License
Tools for exploiting Morphological Symmetries in robotics
Home Page: https://danfoa.github.io/MorphoSymm/
License: MIT License
Hi,
When running the following example:
from morpho_symm.utils.robot_utils import load_symmetric_system
robot, G = load_symmetric_system(robot_name='mini_cheetah')
_, v_js = robot.get_joint_space_state()
rep_TqQ_js = G.representations["TqQ_js"]
for g in G.elements:
g_v_js = rep_TqQ_js(g) @ v_js
I get this error:
With the provided permutation and reflection matrice in cfg yaml file, I try to build the representations of Q_js and TqQ_js by using load_symmetric_system,
but it always causes an error from the builtin function group_rep_from_gens as follows:
TypeError Traceback (most recent call last)
Cell In[27], line 1
----> 1 G, value_in_type, policy_in_type, value_out_type, policy_out_type = load_cartpole_G()
Cell In[26], line 31, in load_cartpole_G()
28 rep_po[g_gen] = gen_permutation_matrix(oneline_notation=perm, reflections=refx)
30 # Generate the entire group
---> 31 rep_Q_js = group_rep_from_gens(G, rep_Q_js)
32 rep_po = group_rep_from_gens(G, rep_po)
33 rep_Q_js.name = 'Q_js'
File ~/autodl-tmp/MorphoSymm/morpho_symm/utils/group_utils.py:96, in group_rep_from_gens(G, rep_H)
93 raise NotImplementedError(f"Group {G} not implemented yet.")
95 # Convert Dict[GroupElement, np.ndarray] to escnn Representation
---> 96 rep_escnn = escnn_representation_form_mapping(G, rep_H)
98 return rep_escnn
File ~/autodl-tmp/MorphoSymm/morpho_symm/groups/isotypic_decomposition.py:278, in escnn_representation_form_mapping(G, representation)
276 rep(G.sample()).shape[0] # Size of the representation
277 # Find Q such that iso_cplx(g) = Q @ rep(g) @ Q^-1
is block diagonal with blocks being complex irreps.
--> 278 cplx_irreps, Q = cplx_isotypic_decomposition(G, rep)
279 # Get the size and location of each cplx irrep in iso_cplx(g)
280 cplx_irreps_size = [irrep(G.sample()).shape[0] for irrep in cplx_irreps]
File ~/autodl-tmp/MorphoSymm/morpho_symm/groups/isotypic_decomposition.py:181, in cplx_isotypic_decomposition(G, representation)
179 # Check if each subrepresentation can be further decomposed.
180 for subrep in subreps:
--> 181 n_sub = subrep(G.sample()).shape[0] # Dimension of sub representation
182 is_irred, _ = is_complex_irreducible(G, subrep)
183 if is_irred:
TypeError: 'dict' object is not callable
Ubuntu 20.04
Python 3.8.10
Latest morpho_symm version
Hi,
In the installation section there is the command:
python morpho_symm.robot_symmetry_visualization.py robot=<robot> gui=True
I guess it should be:
python morpho_symm/robot_symmetry_visualization.py robot=<robot> gui=True
I would like to request that the UniTree Go2 robot be added to this library.
The URDF, xacro files, and other supporting materials for the Go2 robot can be found here: https://github.com/unitreerobotics/unitree_ros/tree/master/robots/go2_description
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.