Пример #1
0
        public static void Initialize(int gpuDeviceId = 0)
        {
            KokkosLibrary.Initialize(Environment.ProcessorCount,
                                     gpuDeviceId);

            //AppDomain.CurrentDomain.ProcessExit += View_Dtor;
        }
Пример #2
0
        public static void Initialize(int numCpuThreads,
                                      int gpuDeviceId)
        {
            KokkosLibrary.Initialize(numCpuThreads <= 0 ? Environment.ProcessorCount : numCpuThreads,
                                     gpuDeviceId);

            //AppDomain.CurrentDomain.ProcessExit += View_Dtor;
        }
Пример #3
0
        public static ScopeGuard Get(InitArguments arguments)
        {
            if (!_initialized)
            {
                KokkosLibrary.Initialize(arguments);
                _initialized = true;
            }

            return(new ScopeGuard());
        }
Пример #4
0
        public static ScopeGuard Get(int gpuDeviceId)
        {
            if (!_initialized)
            {
                KokkosLibrary.Initialize(Environment.ProcessorCount, gpuDeviceId);
                _initialized = true;
            }

            return(new ScopeGuard());
        }
Пример #5
0
        public static ScopeGuard Get(int numCpuThreads,
                                     int gpuDeviceId)
        {
            if (!_initialized)
            {
                KokkosLibrary.Initialize(numCpuThreads, gpuDeviceId);
                _initialized = true;
            }

            return(new ScopeGuard());
        }
Пример #6
0
        public static void Initialize(InitArguments arguments)
        {
            KokkosLibrary.Initialize(arguments);

            //AppDomain.CurrentDomain.ProcessExit += View_Dtor;
        }