-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
90f0d77
commit d37c7ef
Showing
3 changed files
with
71 additions
and
137 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,12 +1,40 @@ | ||
cmake_minimum_required(VERSION 3.5) | ||
project(python_workspace) | ||
|
||
# Find dependencies | ||
find_package(ament_cmake REQUIRED) | ||
find_package(rclpy REQUIRED) | ||
find_package(sensor_msgs REQUIRED) | ||
find_package(std_msgs REQUIRED) | ||
find_package(cv_bridge REQUIRED) | ||
find_package(OpenCV REQUIRED) | ||
find_package(pyzed REQUIRED) | ||
find_package(tensorrt REQUIRED) | ||
find_package(pycuda REQUIRED) | ||
find_package(numpy REQUIRED) | ||
find_package(rosidl_default_generators REQUIRED) | ||
|
||
# Custom messages | ||
rosidl_generate_interfaces(${PROJECT_NAME} | ||
"msg/BoundingBox.msg" | ||
"msg/BoundingBoxes.msg" | ||
) | ||
|
||
ament_package() | ||
# Install Python modules | ||
ament_python_install_package(${PROJECT_NAME}) | ||
|
||
# Add these lines after the `ament_python_install_package` command | ||
rosidl_get_typesupport_target(cpp_typesupport_target "${PROJECT_NAME}" "rosidl_typesupport_cpp") | ||
add_dependencies(${PROJECT_NAME} ${cpp_typesupport_target}) | ||
# Install Python scripts | ||
install(DIRECTORY launch/ | ||
DESTINATION share/${PROJECT_NAME}/launch | ||
) | ||
|
||
install(DIRECTORY config/ | ||
DESTINATION share/${PROJECT_NAME}/config | ||
) | ||
|
||
# Install msg files | ||
install(DIRECTORY msg/ | ||
DESTINATION share/${PROJECT_NAME}/msg | ||
) | ||
|
||
ament_package() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,63 +1,30 @@ | ||
<?xml version="1.0"?> | ||
<?xml-model href="http://download.ros.org/schema/package_format3.xsd" schematypens="http://www.w3.org/2001/XMLSchema"?> | ||
<package format="3"> | ||
<name>node_test</name> | ||
<version>0.0.1</version> | ||
<description>Node Architecture Node</description> | ||
<maintainer email="[email protected]">ishaan_datta</maintainer> | ||
<license>Apache License 2.0</license> | ||
|
||
<buildtool_depend>rosidl_default_generators</buildtool_depend> | ||
|
||
<build_depend>message_generation</build_depend> | ||
<build_depend>rosidl_default_generators</build_depend> | ||
<build_depend>builtin_interfaces</build_depend> | ||
<build_depend>std_msgs</build_depend> | ||
|
||
<exec_depend>message_runtime</exec_depend> | ||
<exec_depend>rclpy</exec_depend> | ||
<exec_depend>std_msgs</exec_depend> | ||
<exec_depend>sensor_msgs</exec_depend> | ||
<exec_depend>rosidl_default_runtime</exec_depend> | ||
<exec_depend>builtin_interfaces</exec_depend> | ||
<exec_depend>geometry_msgs</exec_depend> | ||
|
||
<member_of_group>rosidl_interface_packages</member_of_group> | ||
|
||
<test_depend>ament_lint_auto</test_depend> | ||
<test_depend>ament_lint_common</test_depend> | ||
<test_depend>ament_copyright</test_depend> | ||
<test_depend>ament_flake8</test_depend> | ||
<test_depend>ament_pep257</test_depend> | ||
<test_depend>python3-pytest</test_depend> | ||
|
||
<export> | ||
<build_type>ament_python</build_type> | ||
</export> | ||
</package> | ||
|
||
<!-- <build_depend>rosidl_default_generators</build_depend> | ||
<exec_depend>rosidl_default_runtime</exec_depend> --> | ||
|
||
<!-- newww!!! --> | ||
<?xml version="1.0"?> | ||
<?xml-model href="http://download.ros.org/schema/package_format3.xsd" schematypens="http://www.w3.org/2001/XMLSchema"?> | ||
<package format="3"> | ||
<name>python_workspace</name> | ||
<version>0.0.0</version> | ||
<description>TODO: Package description</description> | ||
<maintainer email="[email protected]">user</maintainer> | ||
<license>TODO: License declaration</license> | ||
<description>Python workspace for ROS2 nodes using custom interfaces</description> | ||
<maintainer email="[email protected]">user</maintainer> | ||
<license>Apache License 2.0 </license> | ||
|
||
<buildtool_depend>ament_cmake</buildtool_depend> | ||
<buildtool_depend>rosidl_default_generators</buildtool_depend> | ||
|
||
<depend>rclpy</depend> | ||
<depend>sensor_msgs</depend> | ||
|
||
<test_depend>ament_copyright</test_depend> | ||
<test_depend>ament_flake8</test_depend> | ||
<test_depend>ament_pep257</test_depend> | ||
<test_depend>python3-pytest</test_depend> | ||
<depend>std_msgs</depend> | ||
<depend>cv_bridge</depend> | ||
<depend>opencv</depend> | ||
<depend>pyzed</depend> | ||
<depend>numpy</depend> | ||
<depend>tensorrt</depend> | ||
<depend>pycuda</depend> | ||
<depend>rosidl_default_runtime</depend> | ||
|
||
<!-- Custom messages --> | ||
<depend>message_generation</depend> --> | ||
|
||
<export> | ||
<build_type>ament_python</build_type> | ||
<build_type>ament_cmake</build_type> | ||
</export> | ||
</package> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,81 +1,6 @@ | ||
from setuptools import setup | ||
|
||
package_name = 'node_test' | ||
|
||
setup( | ||
name=package_name, | ||
version='0.0.1', | ||
packages=[package_name], | ||
data_files=[ | ||
('share/ament_index/resource_index/packages', | ||
['resource/' + package_name]), | ||
('share/' + package_name, ['package.xml']), | ||
('share/' + package_name + '/msg', ['msg/BoundingBox.msg']), | ||
], | ||
install_requires=['setuptools'], | ||
zip_safe=True, | ||
maintainer='ishaan_datta', | ||
maintainer_email='[email protected]', | ||
description='Experimental ROS 2 Python Package', | ||
license='Apache License 2.0', | ||
tests_require=['pytest'], | ||
entry_points={ | ||
'console_scripts': [ | ||
'camera_node = node_test.camera_node:main', | ||
'jetson_node = node_test.jetson_node:main', | ||
'display_node = node_test.display_node:main' | ||
], | ||
}, | ||
) | ||
|
||
# from setuptools import setup | ||
|
||
# package_name = 'node_test' | ||
|
||
# setup( | ||
# name=package_name, | ||
# version='0.0.0', | ||
# packages=[package_name], | ||
# py_modules=[], | ||
# install_requires=['setuptools'], | ||
# zip_safe=True, | ||
# maintainer='your_name', | ||
# maintainer_email='[email protected]', | ||
# description='ROS 2 package with a TensorRT inference node.', | ||
# license='Apache License 2.0', | ||
# tests_require=['pytest'], | ||
# entry_points={ | ||
# 'console_scripts': [ | ||
# 'jetson_node = node_test.jetson_node:main', | ||
# ], | ||
# }, | ||
# ) | ||
|
||
# from setuptools import setup | ||
|
||
# package_name = 'node_test' | ||
|
||
# setup( | ||
# name=package_name, | ||
# version='0.0.0', | ||
# packages=[package_name], | ||
# py_modules=[], | ||
# install_requires=['setuptools'], | ||
# zip_safe=True, | ||
# maintainer='your_name', | ||
# maintainer_email='[email protected]', | ||
# description='ROS 2 package with a TensorRT inference node.', | ||
# license='Apache License 2.0', | ||
# tests_require=['pytest'], | ||
# entry_points={ | ||
# 'console_scripts': [ | ||
# 'jetson_node = node_test.jetson_node:main', | ||
# 'bounding_box_publisher = node_test.bounding_box_publisher:main', | ||
# ], | ||
# }, | ||
# ) | ||
|
||
from setuptools import find_packages, setup | ||
from glob import glob | ||
import os | ||
|
||
package_name = 'python_workspace' | ||
|
||
|
@@ -87,16 +12,30 @@ | |
('share/ament_index/resource_index/packages', | ||
['resource/' + package_name]), | ||
('share/' + package_name, ['package.xml']), | ||
# ('share/' + package_name + '/msg', ['msg/BoundingBox.msg']), | ||
# ('share/' + package_name + '/msg', ['msg/BoundingBoxes.msg']), | ||
(os.path.join('share', package_name, 'msg'), glob('msg/*.msg')), | ||
], | ||
install_requires=[ | ||
'setuptools', | ||
'rclpy', | ||
'cv_bridge', | ||
'numpy', | ||
'opencv-python', | ||
'pycuda', | ||
'tensorrt' | ||
], | ||
install_requires=['setuptools'], | ||
zip_safe=True, | ||
maintainer='user', | ||
maintainer_email='[email protected]', | ||
description='TODO: Package description', | ||
license='TODO: License declaration', | ||
maintainer='ishaan_datta', | ||
maintainer_email='[email protected]', | ||
description='Experimental ROS 2 Python Package', | ||
license='Apache License 2.0', | ||
tests_require=['pytest'], | ||
entry_points={ | ||
'console_scripts': [ | ||
'camera = python_workspace.camera_node:main', | ||
'jetson = python_workspace.jetson_node:main', | ||
'extermination = python_workspace.extermination_node:main' | ||
], | ||
}, | ||
) |