Exemple #1
0
        public static async Task <Detector> LoadAsync(string networkName, CancellationToken ct)
        {
            var core = new InferenceEngineCore();

            try
            {
                return(await LoadAsync(core, networkName, ct));
            }
            catch (Exception)
            {
                core.Dispose();
                throw;
            }
        }
Exemple #2
0
        public Detector(string networkName)
        {
            var core = new InferenceEngineCore();

            try
            {
                _network = new InferenceEngineNetwork(core, networkName);
                Core     = core;
            }
            catch (Exception)
            {
                core.Dispose();
                throw;
            }
        }