예제 #1
0
    def __init__(self, manager):
        OpenRTM_aist.DataFlowComponentBase.__init__(self, manager)

        inImage_arg = [None] * ((len(Img._d_TimedCameraImage) - 4) / 2)
        self._d_inImage = Img.TimedCameraImage(*inImage_arg)
        """
		"""
        self._inImageIn = OpenRTM_aist.InPort("inImage", self._d_inImage)
        self._d_inString = OpenRTM_aist.instantiateDataType(RTC.TimedString)
        """
		"""
        self._inStringIn = OpenRTM_aist.InPort("inString", self._d_inString)
        outImage_arg = [None] * ((len(Img._d_TimedCameraImage) - 4) / 2)
        self._d_outImage = Img.TimedCameraImage(
            RTC.Time(0, 0),
            Img.CameraImage(RTC.Time(0, 0), Img.ImageData(0, 0, 0, []),
                            Img.CameraIntrinsicParameter([], []), []), 0)
        """
		"""
        self._outImageOut = OpenRTM_aist.OutPort("outImage", self._d_outImage)
        self._d_outObjectParam = OpenRTM_aist.instantiateDataType(
            ObjectRecognition.TimedObjectParamSeq)
        """
		"""
        self._outObjectParamOut = OpenRTM_aist.OutPort("outObjectParam",
                                                       self._d_outObjectParam)
        self._d_outFlag = OpenRTM_aist.instantiateDataType(RTC.TimedLong)
        """
		"""
        self._outFlagOut = OpenRTM_aist.OutPort("outFlag", self._d_outFlag)

        # initialize of configuration-data.
        # <rtc-template block="init_conf_param">
        """
		
		 - Name:  dataset
		 - DefaultValue: karuta
		"""
        self._dataset = ['karuta']
        """
		
		 - Name:  mode
		 - DefaultValue: gpu
		"""
        self._mode = ['gpu']
        """
		
		 - Name:  net
		 - DefaultValue: vgg16
		"""
        self._net = ['vgg16']
        """
		
		 - Name:  recognitionRate
		 - DefaultValue: 0.8
		"""
        self._recognitionRate = [0.8]
    def __init__(self, manager):
        OpenRTM_aist.DataFlowComponentBase.__init__(self, manager)

        camera_arg = [None] * ((len(Img._d_TimedCameraImage) - 4) / 2)
        self._d_camera = Img.TimedCameraImage(*camera_arg)
        """
        """
        self._cameraIn = OpenRTM_aist.InPort("camera", self._d_camera)
        """
        """
        self._manipCommonPort = OpenRTM_aist.CorbaPort("manipCommon")
        """
        """
        self._manipMiddlePort = OpenRTM_aist.CorbaPort("manipMiddle")
        """
        """
        self._manipCommon = OpenRTM_aist.CorbaConsumer(
            interfaceType=JARA_ARM.ManipulatorCommonInterface_Common)
        """
        """
        self._manipMiddle = OpenRTM_aist.CorbaConsumer(
            interfaceType=JARA_ARM.ManipulatorCommonInterface_Middle)

        # initialize of configuration-data.
        # <rtc-template block="init_conf_param">
        """
        
         - Name:  debug
         - DefaultValue: 1
        """
        self._debug = [1]

        self._model = None
        """
        
         - Name:  gripper_close_ratio
         - DefaultValue: 0.1
        """
        self._gripper_close_ratio = [0.1]

        #self._model = None

        # the position for taking a picture
        self._camera_jointPos0 = [1.57076]
        self._camera_jointPos1 = [0]
        self._camera_jointPos2 = [1.57076]
        self._camera_jointPos3 = [0]
        self._camera_jointPos4 = [1.57076]
        self._camera_jointPos5 = [0]

        #the initial position
        self._initial_jointPos0 = [1.57076]
        self._initial_jointPos1 = [0]
        self._initial_jointPos2 = [1.57076]
        self._initial_jointPos3 = [0]
        self._initial_jointPos4 = [1.57076]
        self._initial_jointPos5 = [0]
    def __init__(self, manager):
        OpenRTM_aist.DataFlowComponentBase.__init__(self, manager)

        camera_arg = [None] * ((len(Img._d_TimedCameraImage) - 4) / 2)
        self._d_camera = Img.TimedCameraImage(*camera_arg)
        """
        """
        self._cameraIn = OpenRTM_aist.InPort("camera", self._d_camera)
        """
        """
        self._manipCommon_RPort = OpenRTM_aist.CorbaPort("manipCommon_R")
        """
        """
        self._manipMiddle_RPort = OpenRTM_aist.CorbaPort("manipMiddle_R")

        self._manipCommon_LPort = OpenRTM_aist.CorbaPort("manipCommon_L")
        """
        """
        self._manipMiddle_LPort = OpenRTM_aist.CorbaPort("manipMiddle_L")
        """
        """
        self._manipCommon_R = OpenRTM_aist.CorbaConsumer(
            interfaceType=JARA_ARM.ManipulatorCommonInterface_Common)
        """
        """
        self._manipMiddle_R = OpenRTM_aist.CorbaConsumer(
            interfaceType=JARA_ARM.ManipulatorCommonInterface_Middle)
        """
        """
        self._manipCommon_L = OpenRTM_aist.CorbaConsumer(
            interfaceType=JARA_ARM_LEFT.ManipulatorCommonInterface_Common)
        """
        """
        self._manipMiddle_L = OpenRTM_aist.CorbaConsumer(
            interfaceType=JARA_ARM_LEFT.ManipulatorCommonInterface_Middle)

        # initialize of configuration-data.
        # <rtc-template block="init_conf_param">
        """

         - Name:  debug
         - DefaultValue: 1
        """
        self._debug = [1]

        self._model = None
        """

         - Name:  gripper_close_ratio
         - DefaultValue: 0.1
        """
        self._gripper_close_ratio = [0.1]

        self._model = None
예제 #4
0
    def __init__(self, manager):
        OpenRTM_aist.DataFlowComponentBase.__init__(self, manager)

        self._d_InImage = Img.TimedCameraImage(RTC.Time(0, 0), 0, 0)
        """
        """
        self._InImageIn = OpenRTM_aist.InPort("InImage", self._d_InImage)
        self._d_InIRSignal = RTC.TimedLongSeq(RTC.Time(0, 0), [])
        """
        """
        self._InIRSignalIn = OpenRTM_aist.InPort("InIRSignal",
                                                 self._d_InIRSignal)
        self._d_OutLongSeq = RTC.TimedLongSeq(RTC.Time(0, 0), [])
        """
        """
        self._OutLongSeqOut = OpenRTM_aist.OutPort("OutLongSeq",
                                                   self._d_OutLongSeq)
        self._d_Instruction = RTC.TimedString(RTC.Time(0, 0), 0)
        """
        """
        self._InstructionOut = OpenRTM_aist.OutPort("Instruction",
                                                    self._d_Instruction)