mirror of
https://github.com/NGSolve/netgen.git
synced 2025-01-13 14:40:35 +05:00
use global communicator in python-mesh
This commit is contained in:
parent
0f4ca1c7a7
commit
ee24e786af
@ -506,6 +506,7 @@ DLL_HEADER void ExportNetgenMeshing(py::module &m)
|
|||||||
.def(py::init( [] (int dim)
|
.def(py::init( [] (int dim)
|
||||||
{
|
{
|
||||||
auto mesh = make_shared<Mesh>();
|
auto mesh = make_shared<Mesh>();
|
||||||
|
mesh->SetCommunicator(netgen::ng_comm);
|
||||||
mesh -> SetDimension(dim);
|
mesh -> SetDimension(dim);
|
||||||
SetGlobalMesh(mesh); // for visualization
|
SetGlobalMesh(mesh); // for visualization
|
||||||
mesh -> SetGeometry (nullptr);
|
mesh -> SetGeometry (nullptr);
|
||||||
@ -533,8 +534,8 @@ DLL_HEADER void ExportNetgenMeshing(py::module &m)
|
|||||||
istream * infile;
|
istream * infile;
|
||||||
|
|
||||||
#ifdef PARALLEL
|
#ifdef PARALLEL
|
||||||
MPI_Comm_rank(MPI_COMM_WORLD, &id);
|
MPI_Comm_rank(netgen::ng_comm, &id);
|
||||||
MPI_Comm_size(MPI_COMM_WORLD, &ntasks);
|
MPI_Comm_size(netgen::ng_comm, &ntasks);
|
||||||
|
|
||||||
char* buf = nullptr;
|
char* buf = nullptr;
|
||||||
int strs = 0;
|
int strs = 0;
|
||||||
|
Loading…
Reference in New Issue
Block a user