Skip to content

Commit

Permalink
Merge branch 'develop' of github.com:nasa/isaac into survey_manager_e…
Browse files Browse the repository at this point in the history
…xecute_goals
  • Loading branch information
marinagmoreira committed Nov 16, 2023
2 parents 8456b90 + 5010fc9 commit ad57def
Show file tree
Hide file tree
Showing 16 changed files with 26 additions and 194 deletions.
21 changes: 0 additions & 21 deletions .github/workflows/ci_pr.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,27 +28,6 @@ jobs:
- name: Build code for isaac:astrobee Ubuntu 16
run: isaac/scripts/docker/build.sh --remote --xenial --astrobee-source-path astrobee/


build-bionic:

runs-on: ubuntu-20.04

steps:

- name: Checkout Astrobee
uses: actions/checkout@v3
with:
repository: nasa/astrobee
path: astrobee/

- name: Checkout ISAAC
uses: actions/checkout@v3
with:
submodules: recursive
path: isaac/

- name: Build code for isaac:astrobee Ubuntu 18
run: isaac/scripts/docker/build.sh --remote --bionic --astrobee-source-path astrobee/
build-focal:

runs-on: ubuntu-20.04
Expand Down
59 changes: 0 additions & 59 deletions .github/workflows/ci_push.yml
Original file line number Diff line number Diff line change
Expand Up @@ -67,65 +67,6 @@ jobs:
if [ "${{ github.repository_owner }}" = "nasa" ]; then docker push ghcr.io/${{ github.repository_owner }}/isaac:astrobee-msgs-ubuntu16.04; fi;
if [ "${{ github.repository_owner }}" = "nasa" ]; then docker push ghcr.io/${{ github.repository_owner }}/isaac:msgs-ubuntu16.04; fi;
build-bionic:

runs-on: ubuntu-20.04

steps:

- name: Checkout Astrobee
uses: actions/checkout@v3
with:
repository: nasa/astrobee
path: astrobee/

- name: Checkout ISAAC
uses: actions/checkout@v3
with:
submodules: recursive
path: isaac/

- name: Build code for isaac:astrobee Ubuntu 18
run: docker build isaac -f isaac/scripts/docker/isaac_astrobee.Dockerfile
--build-arg UBUNTU_VERSION=18.04
--build-arg ROS_VERSION=melodic
--build-arg PYTHON=3
--build-arg REMOTE=ghcr.io/nasa
-t ghcr.io/${{ github.repository_owner }}/isaac:latest-astrobee-ubuntu18.04

- name: Build code for isaac:latest Ubuntu 18
run: docker build isaac -f isaac/scripts/docker/isaac.Dockerfile
--build-arg UBUNTU_VERSION=18.04
--build-arg ROS_VERSION=melodic
--build-arg PYTHON=3
--build-arg REMOTE=ghcr.io/nasa
-t ghcr.io/${{ github.repository_owner }}/isaac:latest-ubuntu18.04

- name: Build messages dockers for Ubuntu 18 (astrobee)
run: docker build astrobee -f isaac/scripts/docker/astrobee_msgs.Dockerfile
--build-arg UBUNTU_VERSION=18.04
--build-arg ROS_VERSION=melodic
--build-arg PYTHON=''
-t ghcr.io/${{ github.repository_owner }}/isaac:astrobee-msgs-ubuntu18.04

- name: Build messages dockers for Ubuntu 18 (isaac)
run: docker build isaac -f isaac/scripts/docker/isaac_msgs.Dockerfile
--build-arg UBUNTU_VERSION=18.04
--build-arg ROS_VERSION=melodic
--build-arg PYTHON=''
--build-arg REMOTE=ghcr.io/nasa
-t ghcr.io/${{ github.repository_owner }}/isaac:msgs-ubuntu18.04

- name: Log in to registry
run: echo "${{ secrets.GITHUB_TOKEN }}" | docker login ghcr.io -u ${{ github.repository_owner }} --password-stdin

- name: Push Docker image
run: |
if [ "${{ github.repository_owner }}" = "nasa" ]; then docker push ghcr.io/${{ github.repository_owner }}/isaac:latest-astrobee-ubuntu18.04; fi;
if [ "${{ github.repository_owner }}" = "nasa" ]; then docker push ghcr.io/${{ github.repository_owner }}/isaac:latest-ubuntu18.04; fi;
if [ "${{ github.repository_owner }}" = "nasa" ]; then docker push ghcr.io/${{ github.repository_owner }}/isaac:astrobee-msgs-ubuntu18.04; fi;
if [ "${{ github.repository_owner }}" = "nasa" ]; then docker push ghcr.io/${{ github.repository_owner }}/isaac:msgs-ubuntu18.04; fi;
build-focal:

runs-on: ubuntu-20.04
Expand Down
60 changes: 0 additions & 60 deletions .github/workflows/ci_release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -70,66 +70,6 @@ jobs:
docker tag isaac/isaac:latest-ubuntu16.04 ghcr.io/${{ github.repository_owner }}/isaac:v${VERSION}-ubuntu16.04
if [ "${{ github.repository_owner }}" = "nasa" ]; then docker push ghcr.io/${{ github.repository_owner }}/isaac:v${VERSION}-ubuntu16.04; fi;
build-bionic:

runs-on: ubuntu-20.04

steps:
- name: Checkout Astrobee
uses: actions/checkout@v3
with:
repository: nasa/astrobee
path: astrobee/

- name: Checkout ISAAC
uses: actions/checkout@v3
with:
submodules: recursive
path: isaac/

- name: Build code for isaac:astrobee Ubuntu 18
run: docker build isaac -f isaac/scripts/docker/isaac_astrobee.Dockerfile
--build-arg UBUNTU_VERSION=18.04
--build-arg ROS_VERSION=melodic
--build-arg PYTHON=3
--build-arg REMOTE=ghcr.io/nasa
-t isaac/isaac:latest-astrobee-ubuntu18.04

- name: Build code for isaac:latest Ubuntu 18
run: docker build isaac -f isaac/scripts/docker/isaac.Dockerfile
--build-arg UBUNTU_VERSION=18.04
--build-arg ROS_VERSION=melodic
--build-arg PYTHON=3
--build-arg REMOTE=isaac
-t isaac/isaac:latest-ubuntu18.04

- name: Build messages dockers for Ubuntu 18 (astrobee)
run: docker build astrobee -f isaac/scripts/docker/astrobee_msgs.Dockerfile
--build-arg UBUNTU_VERSION=18.04
--build-arg ROS_VERSION=melodic
--build-arg PYTHON=''
-t isaac/isaac:astrobee-msgs-ubuntu18.04

- name: Build messages dockers for Ubuntu 18 (isaac)
run: docker build isaac -f isaac/scripts/docker/isaac_msgs.Dockerfile
--build-arg UBUNTU_VERSION=18.04
--build-arg ROS_VERSION=melodic
--build-arg PYTHON=''
--build-arg REMOTE=isaac
-t isaac/isaac:msgs-ubuntu18.04

- name: Log in to registry
run: echo "${{ secrets.GITHUB_TOKEN }}" | docker login ghcr.io -u ${{ github.repository_owner }} --password-stdin

- name: Push Docker image
run: |
cd isaac
export VERSION=`grep -w -m 1 "Release" RELEASE.md | awk '{print $3}'`
docker tag isaac/isaac:latest-astrobee-ubuntu18.04 ghcr.io/${{ github.repository_owner }}/isaac:v${VERSION}-astrobee-ubuntu18.04
if [ "${{ github.repository_owner }}" = "nasa" ]; then docker push ghcr.io/${{ github.repository_owner }}/isaac:v${VERSION}-astrobee-ubuntu18.04; fi;
docker tag isaac/isaac:latest-ubuntu18.04 ghcr.io/${{ github.repository_owner }}/isaac:v${VERSION}-ubuntu18.04
if [ "${{ github.repository_owner }}" = "nasa" ]; then docker push ghcr.io/${{ github.repository_owner }}/isaac:v${VERSION}-ubuntu18.04; fi;
build-focal:

runs-on: ubuntu-20.04
Expand Down
4 changes: 2 additions & 2 deletions INSTALL.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,15 +4,15 @@ Native Install
Machine setup
---------

Install the 64-bit version of [Ubuntu 16.04, 18.04 or 20.04](http://releases.ubuntu.com/)
Install the 64-bit version of [Ubuntu 16.04 or 20.04](http://releases.ubuntu.com/)
on a host machine, and make sure that you can checkout and build code.

sudo apt-get install build-essential git

*Note: You will need 4 GBs of RAM to compile the software. If you don't have
that much RAM available, please use swap space.*

*Note: Please ensure you install Ubuntu 16.04, 18.04 or 20.04. At this time we do not support
*Note: Please ensure you install Ubuntu 16.04 or 20.04. At this time we do not support
any other operating system or Ubuntu versions.*

*Note: Please ensure you install the 64-bit version of Ubuntu. We do not
Expand Down
2 changes: 1 addition & 1 deletion analyst/tools/query_view_points.cc
Original file line number Diff line number Diff line change
Expand Up @@ -114,7 +114,7 @@ int main(int argc, char** argv) {
new geometry_msgs::Transform(msg_conversions::eigen_transform_to_ros_transform(transform_body_to_cam)));

camera::CameraParameters cam_params(&config, FLAGS_camera.c_str());
inspection::CameraView camera(cam_params, 2.0, 0.19, msg_pointer);
inspection::CameraView camera(FLAGS_camera, cam_params, 2.0, 0.19, msg_pointer);


// Extract the input list from the command-line argument
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -69,9 +69,8 @@ class CameraView : public camera::CameraModel {
// f: far clip, maximum camera distance (m)
// n: near clip, minimum camera distance (m)
// cam_transform: transform from body->camera, useful for offline applications where tf is not available
CameraView(const camera::CameraParameters & params, const float f = 2.0, const float n = 0.19,
const geometry_msgs::Transform::ConstPtr cam_transform = NULL);

CameraView(const std::string& cam_name, const camera::CameraParameters& params, const float f = 2.0,
const float n = 0.19, const geometry_msgs::Transform::ConstPtr cam_transform = NULL);

// Gets the points x y where the point is in the image. If outside the image, then it will return false
// If the robot pose is not specified, it's considered to be the current one
Expand Down
11 changes: 6 additions & 5 deletions astrobee/behaviors/inspection/src/camera_projection.cc
Original file line number Diff line number Diff line change
Expand Up @@ -34,10 +34,11 @@ namespace inspection {
the camera frame and the other way around. It automatically reads the camera parameters
from the config files based on the camera name, such that no setup is necessary.
*/
CameraView::CameraView(const camera::CameraParameters & params, const float f, const float n,
const geometry_msgs::Transform::ConstPtr cam_transform)
: camera::CameraModel(params), f_(f), n_(n) {

CameraView::CameraView(const std::string& cam_name, const camera::CameraParameters& params, const float f,
const float n, const geometry_msgs::Transform::ConstPtr cam_transform)
: cam_name_(cam_name), camera::CameraModel(params), f_(f), n_(n) {
cfg_cam_.AddFile("cameras.config");
if (!cfg_cam_.ReadFiles()) ROS_FATAL("Failed to read config files.");
// Get relative camera position
if (cam_transform == NULL) {
// Create a transform buffer to listen for transforms
Expand Down Expand Up @@ -147,7 +148,7 @@ bool CameraView::InsideTarget(std::vector<int> vert_x, std::vector<int> vert_y,
double size_y) {
// Create depth cam camera model
static camera::CameraParameters depth_cam_params(&cfg_cam_, (depth_cam_name + "_cam").c_str());
CameraView depth_cam(depth_cam_params, f_, n_);
CameraView depth_cam(depth_cam_name + "_cam", depth_cam_params, f_, n_);

// Get most recent depth message
std::string cam_prefix = TOPIC_HARDWARE_PICOFLEXX_PREFIX;
Expand Down
10 changes: 6 additions & 4 deletions astrobee/behaviors/inspection/src/inspection.cc
Original file line number Diff line number Diff line change
Expand Up @@ -436,8 +436,9 @@ bool Inspection::GenerateAnomalySurvey(geometry_msgs::PoseArray &points_anomaly)
curr_camera_ = cam_name.c_str();
if (cameras_.find(cam_name) == cameras_.end()) {
static camera::CameraParameters cam_params(&cfg_cam_, cam_name.c_str());
cameras_.emplace(std::piecewise_construct, std::make_tuple(cam_name),
std::make_tuple(cam_params, cfg_->Get<double>("max_distance"), cfg_->Get<double>("min_distance")));
cameras_.emplace(
std::piecewise_construct, std::make_tuple(cam_name),
std::make_tuple(cam_name, cam_params, cfg_->Get<double>("max_distance"), cfg_->Get<double>("min_distance")));
}


Expand Down Expand Up @@ -523,8 +524,9 @@ bool Inspection::GeneratePanoramaSurvey(geometry_msgs::PoseArray &points_panoram
curr_camera_ = cam_name.c_str();
if (cameras_.find(cam_name) == cameras_.end()) {
static camera::CameraParameters cam_params(&cfg_cam_, cam_name.c_str());
cameras_.emplace(std::piecewise_construct, std::make_tuple(cam_name),
std::make_tuple(cam_params, cfg_->Get<double>("max_distance"), cfg_->Get<double>("min_distance")));
cameras_.emplace(
std::piecewise_construct, std::make_tuple(cam_name),
std::make_tuple(cam_name, cam_params, cfg_->Get<double>("max_distance"), cfg_->Get<double>("min_distance")));
}

geometry_msgs::PoseArray panorama_relative;
Expand Down
2 changes: 1 addition & 1 deletion astrobee/behaviors/inspection/tools/inspection_tool.cc
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,7 @@ DEFINE_string(att, "", "Desired attitude in RPY format 'roll pitch yaw' (degrees

// Plan files
DEFINE_string(anomaly_poses, "/resources/inspection_iss.txt", "Vent pose list to inspect");
DEFINE_string(geometry_poses, "/resources/survey_bay_6.txt", "Geometry poses list to map");
DEFINE_string(geometry_poses, "/resources/geometry_iss.txt", "Geometry poses list to map");
DEFINE_string(panorama_poses, "/resources/panorama_iss.txt", "Panorama poses list to map");
DEFINE_string(volumetric_poses, "/resources/volumetric_iss.txt", "Wifi poses list to map");

Expand Down
2 changes: 1 addition & 1 deletion pano/pano_view/tools/find_point_coordinate.cc
Original file line number Diff line number Diff line change
Expand Up @@ -215,7 +215,7 @@ int main(int argc, char** argv) {
new geometry_msgs::Transform(msg_conversions::eigen_transform_to_ros_transform(transform_body_to_cam)));

camera::CameraParameters cam_params(&config, camera_name.c_str());
inspection::CameraView camera(cam_params, 2.0, 0.19, msg_pointer);
inspection::CameraView camera(camera_name, cam_params, 2.0, 0.19, msg_pointer);
camera.SetTransform((msg_conversions::ros_pose_to_eigen_transform(ground_truth) * transform_body_to_cam).inverse());


Expand Down
4 changes: 1 addition & 3 deletions scripts/configure.sh
Original file line number Diff line number Diff line change
Expand Up @@ -228,8 +228,6 @@ ff_path=`canonicalize ${rootpath}`
DIST=`cat /etc/os-release | grep -oP "(?<=VERSION_CODENAME=).*"`
if [ "$DIST" = "xenial" ]; then
ros_version=kinetic
elif [ "$DIST" = "bionic" ]; then
ros_version=melodic
elif [ "$DIST" = "focal" ]; then
ros_version=noetic
fi
Expand Down Expand Up @@ -317,7 +315,7 @@ if [ $armhf_build == 1 ] ; then
--install \
--cmake-args -DARMHF_CHROOT_DIR=$ARMHF_CHROOT_DIR ${armhf_opts} ${use_ctc} ${extra_opts} \
-DCMAKE_BUILD_TYPE=Release
if [ "$DIST" = "xenial" ] || [ "$DIST" = "bionic" ]; then
if [ "$DIST" = "xenial" ]; then
catkin config \
--whitelist isaac_astrobee_description isaac_util isaac_msgs inspection cargo isaac_hw_msgs wifi isaac gs_action_helper
elif [ "$DIST" = "focal" ]; then
Expand Down
9 changes: 1 addition & 8 deletions scripts/docker/build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,6 @@ print_help()
echo -e "define the docker files variables UBUNTU_VERSION, ROS_VERSION, and PYTHON accordingly."
echo -e "Options:"
echo -e "\t-x | --xenial\t\t\tBuild images for Ubuntu 16.04"
echo -e "\t-b | --bionic\t\t\tBuild images for Ubuntu 18.04"
echo -e "\t-f | --focal\t\t\tBuild images for Ubuntu 20.04"
echo -e "\t-a | --astrobee-source-path\tSpecify the astrobee source directory to use"
echo -e "\t\t\t\tdefault=isaac_source/../../astrobee"
Expand Down Expand Up @@ -59,8 +58,6 @@ while [ "$1" != "" ]; do
case $1 in
-x | --xenial ) os="xenial"
;;
-b | --bionic ) os="bionic"
;;
-f | --focal ) os="focal"
;;
-a | --astrobee-source-path ) shift
Expand Down Expand Up @@ -110,10 +107,6 @@ if [ "$os" == "xenial" ]; then
export UBUNTU_VERSION=16.04
export ROS_VERSION=kinetic
export PYTHON=''
elif [ "$os" == "bionic" ]; then
export UBUNTU_VERSION=18.04
export ROS_VERSION=melodic
export PYTHON=''
elif [ "$os" == "focal" ]; then
export UBUNTU_VERSION=20.04
export ROS_VERSION=noetic
Expand Down Expand Up @@ -151,4 +144,4 @@ if [ $mast == 1 ]; then
files+=" -f ${script_dir}/docker_compose/mast.docker-compose.yml"
fi

docker compose ${files} build
docker compose ${files} build
8 changes: 4 additions & 4 deletions scripts/docker/readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,8 @@ If you want to build the docker images locally instead of pulling from the remot
./build --help

The build script will automatically detect the current Ubuntu OS version and define the docker files variables
`UBUNTU_VERSION`, `ROS_VERSION`, and `PYTHON` accordingly. If a specific version is desired, the option --xenial, --bionic,
and --focal is used for ubuntu 16.04, 18.04, and 20.04 docker images, respectively.
`UBUNTU_VERSION`, `ROS_VERSION`, and `PYTHON` accordingly. If a specific version is desired, the options --xenial
and --focal are used for Ubuntu 16.04 and 20.04 docker images, respectively.

If you don't want to run mast or don't have access to it (not a public repository), the use the option --no-mast.

Expand All @@ -41,8 +41,8 @@ To run the docker containers:
Make sure the default paths are correct, if not configure those options. Read through the
different optional modules to understand if it fits your purpose.

It will automatically detect the current Ubuntu OS version. If a specific version is desired, the option
--xenial, --bionic, and --focal is used for ubuntu 16.04, 18.04, and 20.04 docker images, respectively.
It will automatically detect the current Ubuntu OS version. If a specific version is desired, the options
--xenial and --focal are used for Ubuntu 16.04 and 20.04 docker images, respectively.

Once the command is executed the host location of the modules launched will be printed. Open those paths
on your favorite browser.
Expand Down
9 changes: 1 addition & 8 deletions scripts/docker/run.sh
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,6 @@ print_help()
echo -e "define the docker files variables UBUNTU_VERSION, ROS_VERSION, and PYTHON accordingly."
echo -e "Options:"
echo -e "\t-x | --xenial\t\t\tRun images for Ubuntu 16.04"
echo -e "\t-b | --bionic\t\t\tRun images for Ubuntu 18.04"
echo -e "\t-f | --focal\t\t\tRun images for Ubuntu 20.04"
echo -e "\t-i | --iui-source-dir\t\tSpecify the idi source directory to use"
echo -e "\t\t\t\tdefault=isaac_source/../../isaac_data_interface"
Expand Down Expand Up @@ -78,8 +77,6 @@ while [ "$1" != "" ]; do
;;
-x | --xenial ) os="xenial"
;;
-b | --bionic ) os="bionic"
;;
-f | --focal ) os="focal"
;;
-r | --remote ) export REMOTE="ghcr.io/nasa"
Expand Down Expand Up @@ -136,10 +133,6 @@ if [ "$os" == "xenial" ]; then
export UBUNTU_VERSION=16.04
export ROS_VERSION=kinetic
export PYTHON=''
elif [ "$os" == "bionic" ]; then
export UBUNTU_VERSION=18.04
export ROS_VERSION=melodic
export PYTHON=''
elif [ "$os" == "focal" ]; then
export UBUNTU_VERSION=20.04
export ROS_VERSION=noetic
Expand Down Expand Up @@ -278,4 +271,4 @@ echo "Press 'q' to exit"
fi
done

docker compose ${files} down
docker compose ${files} down
8 changes: 0 additions & 8 deletions scripts/setup/build_install_dependencies.sh
Original file line number Diff line number Diff line change
Expand Up @@ -25,14 +25,6 @@ DEP_LOC=$(dirname "$(readlink -f "$0")")/dependencies

sudo apt-get install -y unzip libgtest-dev

# Comes pre-built in Ubuntu 20.04
if [ "$(lsb_release -sr)" = "18.04" ]; then
cd /usr/src/gtest
sudo cmake CMakeLists.txt
sudo make
sudo cp *.a /usr/lib
fi

cd ${DEP_LOC}
./build_install_gp.sh || exit 1

Expand Down
6 changes: 0 additions & 6 deletions scripts/setup/packages_bionic.lst

This file was deleted.

0 comments on commit ad57def

Please sign in to comment.