예제 #1
0
파일: UnitTest1.cs 프로젝트: emgucv/emgutf
        public async Task TestMaskRCNN()
        {
            using (Tensor imageTensor = ImageIO.ReadTensorFromImageFile <byte>(
                       "surfers.jpg",
                       -1,
                       -1,
                       0,
                       1.0f))
                using (MaskRcnnInceptionV2Coco model = new MaskRcnnInceptionV2Coco())
                {
                    await model.Init();

                    MaskRcnnInceptionV2Coco.RecognitionResult[][] results = model.Recognize(imageTensor);
                }
        }
예제 #2
0
        public MainForm()
        {
            InitializeComponent();

            TfInvoke.CheckLibraryLoaded();
            messageLabel.Text = String.Empty;
            cameraButton.Text = "Start Camera";

            DisableUI();

            //Use the following code for the full inception model
            _inceptionGraph = new MaskRcnnInceptionV2Coco();
            _inceptionGraph.OnDownloadProgressChanged += OnDownloadProgressChangedEventHandler;
            _inceptionGraph.OnDownloadCompleted       += onDownloadCompleted;

            _inceptionGraph.Init();
        }