MCPcopy Create free account
hub / github.com/NGSolve/ngsolve / NGSolve_Init

Function NGSolve_Init

solve/ngsolve.cpp:688–814  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

686
687
688int NGSolve_Init (Tcl_Interp * interp)
689{
690 cout << "NGSolve-" << ngsolve_version << endl;
691
692#ifdef LAPACK
693 cout << "Using Lapack" << endl;
694#else
695 cout << "sorry, no lapack" << endl;
696#endif
697
698
699if(is_pardiso_available)
700 cout << "Including sparse direct solver Pardiso" << endl;
701
702#ifdef USE_UMFPACK
703 cout << "Including sparse direct solver UMFPACK" << endl;
704#endif
705
706#ifdef USE_SUPERLU
707 cout << "Including sparse direct solver SuperLU by Lawrence Berkeley National Laboratory" << endl;
708#endif
709
710 if (getenv ("NGSPROFILE"))
711 NgProfiler::SetFileName (string("ngs.prof"));
712
713#ifdef PARALLEL
714 // in MyMPI
715 // if (MyMPI_GetNTasks(MPI_COMM_WORLD) > 1)
716 // TaskManager::SetNumThreads (1);
717#endif
718 cout << "Running parallel using " << TaskManager::GetMaxThreads() << " thread(s)" << endl;
719
720
721
722
723#ifdef SOCKETS
724 if(netgen::serversocketmanager.Good())
725 serverjobmanager.Reset(new ServerJobManager(netgen::serversocketmanager,pde,ma,interp)); //!
726
727#endif
728
729
730
731
732#ifdef NGS_PYTHON
733
734 // Only initialize a python environment if Netgen was started using the executable
735 // In case we start the GUI from python, no further initialization is needed here
736 if(netgen::netgen_executable_started)
737 {
738 Py_Initialize();
739
740#if PY_VERSION_HEX < 0x03090000
741 PyEval_InitThreads();
742#endif
743
744 py::module::import("__main__");
745

Callers 1

Calls 1

execMethod · 0.80

Tested by

no test coverage detected