Skip to main content

Pytorch implementation of Contact Graspnet

Project description

Contact-GraspNet Pytorch

Pytorch implementation of Contact-GraspNet. This repo is based heavily on https://github.com/alinasarmiento/pytorch_contactnet. Original Tensorflow implementation can be found at: https://github.com/NVlabs/contact_graspnet

Installation Instructions

pip install cgn-pytorch

Usage:

import cgn_pytorch

cgn_model, optimizer, config_dict = cgn_pytorch.from_pretrained(cpu=False)

Run The Demo

Clone this Repo

git clone https://github.com/sebbyjp/cgn_pytorch.git

Install Dependencies

pip3 install -r requirements.txt

Vizualization

We're doing our visualizations in MeshCat. In a separate tab, start a meshcat server with meshcat-server

From here you can run python3 eval.py

To visualize different confidence threshold masks on the grasps, use the --threshold argument such as --threshold=0.8

To visualize different cluttered scenes (8-12 tabletop objects rendered in pyrender from ACRONYM), use the argument --scene and manually feed in a file name such as --scene=002330.npz.Your possible files are:

  • 002330.npz
  • 004086.npz
  • 005274.npz

Predicting grasps on your own pointclouds

The model should work on any pointcloud of shape (Nx3). For most consistent results, please make sure to put the pointcloud in the world frame and center it by subtracting the mean. Do not normalize the pointcloud to a unit sphere or unit box, as "graspability" naturally changes depending on the size of the objects (so we don't want to lose that information about the scene by scaling it).

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

cgn_pytorch-0.4.3.tar.gz (30.1 MB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

cgn_pytorch-0.4.3-py3-none-any.whl (30.2 MB view details)

Uploaded Python 3

File details

Details for the file cgn_pytorch-0.4.3.tar.gz.

File metadata

  • Download URL: cgn_pytorch-0.4.3.tar.gz
  • Upload date:
  • Size: 30.1 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.7.1 CPython/3.10.12 Linux/6.4.16-linuxkit

File hashes

Hashes for cgn_pytorch-0.4.3.tar.gz
Algorithm Hash digest
SHA256 e198d580a9a7b908d533d09edf6328b884ffcb363e15690e48e1df4b8c5946cb
MD5 5a57eb494a764e8abe76e9a13ee774f6
BLAKE2b-256 476a8e49b0e5a7303c63e9b62bfd55b6b1cefac51ba01e44a44d1978e3638e72

See more details on using hashes here.

File details

Details for the file cgn_pytorch-0.4.3-py3-none-any.whl.

File metadata

  • Download URL: cgn_pytorch-0.4.3-py3-none-any.whl
  • Upload date:
  • Size: 30.2 MB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.7.1 CPython/3.10.12 Linux/6.4.16-linuxkit

File hashes

Hashes for cgn_pytorch-0.4.3-py3-none-any.whl
Algorithm Hash digest
SHA256 600c1806af6a8a2a9ee6557c988126eea88a2edfd4984384008946572351c160
MD5 9583968d57c0cdd0b63809217574bc46
BLAKE2b-256 97fc88262355ef8d02983152fcdc6a1baa27b662a1306c2b4970df084131087e

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page