ISAAC  0.2.11
Flight software for the ISAAC project, adding functionality to the Astrobee robot, operating inside the International Space Station.
All Classes Functions Variables Pages
img_vent.h
1 /* Copyright (c) 2021, United States Government, as represented by the
2  * Administrator of the National Aeronautics and Space Administration.
3  *
4  * All rights reserved.
5  *
6  * The "ISAAC - Integrated System for Autonomous and Adaptive Caretaking
7  * platform" software is licensed under the Apache License, Version 2.0
8  * (the "License"); you may not use this file except in compliance with the
9  * License. You may obtain a copy of the License at
10  *
11  * http://www.apache.org/licenses/LICENSE-2.0
12  *
13  * Unless required by applicable law or agreed to in writing, software
14  * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
15  * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
16  * License for the specific language governing permissions and limitations
17  * under the License.
18  */
19 
20 #ifndef IMG_ANALYSIS_IMG_VENT_H_
21 #define IMG_ANALYSIS_IMG_VENT_H_
22 
23 // Standard includes
24 #include <ros/ros.h>
25 #include <nodelet/nodelet.h>
26 #include <pluginlib/class_list_macros.h>
27 #include <sensor_msgs/CompressedImage.h>
28 #include <cv_bridge/cv_bridge.h>
29 #include <opencv2/imgproc/imgproc.hpp>
30 #include <opencv2/highgui/highgui.hpp>
31 
32 // FSW includes
33 #include <config_reader/config_reader.h>
34 #include <ff_common/ff_names.h>
35 #include <ff_msgs/AckStamped.h>
36 #include <ff_msgs/CommandConstants.h>
37 #include <ff_msgs/CommandStamped.h>
38 
39 // Torch include
40 #include <torch/script.h>
41 
42 // C++ includes
43 #include <unsupported/Eigen/CXX11/Tensor>
44 #include <Eigen/Dense>
45 #include <string>
46 #include <iostream>
47 #include <memory>
48 
52 namespace img_analysis {
53 
54 class ImgVent {
55  public:
56  ImgVent();
57  int AnalysePic(cv::Mat img);
58 
59  // Vent classification
60  static const int vent_free_ = 0; // Classification of vent as free
61  static const int vent_blocked_ = 1; // Classification of vent as blocked
62  static const int vent_unknown_ = 2; // Classification of vent as unknown
63 
64  private:
65  torch::jit::script::Module module_;
66 };
67 } // namespace img_analysis
68 #endif // IMG_ANALYSIS_IMG_VENT_H_
img_analysis::ImgVent
Definition: img_vent.h:54