Metadata-Version: 2.1
Name: robot-model-tools
Version: 0.1.0
Summary: Misc utilities to work with robot model formats
Author-email: Marco Frigerio <marco.frigerio17@pm.me>
License: Copyright (c) 2019-2020, Marco Frigerio
        All rights reserved.
        
        Redistribution and use in source and binary forms, with or without
        modification, are permitted provided that the following conditions are met:
        
        1. Redistributions of source code must retain the above copyright
           notice, this list of conditions and the following disclaimer.
        
        2. Redistributions in binary form must reproduce the above copyright notice,
           this list of conditions and the following disclaimer in the documentation
           and/or other materials provided with the distribution.
        
        3. Neither the name of the copyright holder nor the names of its contributors
           may be used to endorse or promote products derived from this software without
           specific prior written permission.
        
        THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
        ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
        WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
        DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR
        ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
        (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
        LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
        ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
        (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
        SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
        
Project-URL: home, https://github.com/mfrigerio17/robot-model-tools
Requires-Python: >=3.4
Description-Content-Type: text/markdown
License-File: LICENSE

This is the readme file of the "Robot Model Tools" Python package.

The modules in the `robmodel` package allow to model some aspects of articulated
robots, such as connectivity, numbering scheme of the links, attached frames,
geometry, etc.

The `rmt` package implements a command line program that operates on robot
models, such as the URDF or the KinDSL formats. See

```
rmt --help
```

for a list of the available sub commands.

You can try the program without installing this repository
(although you still need to install the dependencies):
```
cd src/
./runner.py --help
```

# Code documentation

More information about the packages and the modules of this project is available
in the source code.

You can generate e.g. html documentation using [pdoc](https://pdoc.dev/).
For example:

```sh
cd src/
pdoc --no-show-source -o /tmp/docs/rmt rmt/ robmodel/
```

# Installation
```
pip install rmt
```

Alternatively, install from the source code:

```sh
git clone <repo> rmt    # replace <repo> with the right URL
cd rmt/
pip install .           # should also install the dependencies available in PyPI
```


#### Virtual environment
You might want to install the tool and its dependencies in an isolated virtual
environment. If so, run the following before the installation procedure:

```sh
mkdir myvenv && python3 -m venv myvenv
source myvenv/bin/activate  # may need to pick another script depending on your shell
#pip install wheel           # may also required to set up the env
```

## Dependencies
The following libraries are used by this project:

- [kgprim](https://github.com/mfrigerio17/kgprim) kinematics/geometric primitives

- [NetworkX](http://networkx.github.io/), for the connectivity model, which is a
  graph

- [NumPy](http://www.numpy.org)

Optionally:

- [textX](http://textx.github.io/textX/stable/), for the KinDSL format importer

- [PyYAML](http://pyyaml.org), to import YAML models

- [Mako](https://www.makotemplates.org/), for the export of models to other
  formats (which involves text generation)

- [PyGraphviz](https://pygraphviz.github.io/), required only by the DOT file
  generator command of the `rmt` tool


# Testing
Verify your installation by moving to the `test/` folder and running
```
python ur5.py
```


# License

Copyright © 2019-2022, Marco Frigerio

Released under the BSD 3-clause license. See the `LICENSE` file for additional
information.

