Read external mesh data in FEniCSX

Hi,
Am new to dolfinx, and am struggling to read 2D external mesh data file. I have following name tags from my gmsh file :
$PhysicalNames
3
1 2 “convection”
1 3 “coupling”
2 1 “domain”

Currently am using reading the xdmf mesh file using the commands:

with dolfinx.io.XDMFFile(MPI.COMM_WORLD, “mf.xdmf”, “r”) as xdmf:
mesh = xdmf.read_mesh(name=“Grid”)
ct = xdmf.read_meshtags(mesh, name=“Grid”)
mesh.topology.create_connectivity(mesh.topology.dim, mesh.topology.dim-1)

but after this, how can I access my boundary markers assigned? I mean how can use the name tags assigned.

Regards,
GS

DOLFIN and DOLFINx doe snot read in strings. You should use the integer associated with the tag.
See for instance: Defining subdomains for different materials — FEniCSx tutorial

Thanks for the reference document. Currently, I want to install the dolfinx_mpc library on ubuntu 20.04. I am running the following commands:
git clone GitHub - jorgensd/dolfinx_mpc: Extension for dolfinx to handle multi-point constraints. &&
cd dolfinx_mpc &&
git checkout 0.1.0 &&
cmake -G Ninja -DCMAKE_BUILD_TYPE=Developer -B build-dir cpp/ &&
ninja install -j12 -C build-dir &&
pip3 install python/. --upgrade

but I get the following error message :
ninja: build stopped: subcommand failed.

can I kindly get help to install the dolfinx_mpc library?.

Regards,
GS

You need to send me the full error log for me to be able to help you.

Dear Sir,

I have attached the error log file.

Regards,
GS

(Attachment error_dolfinx-mpc.txt is missing)

No file has been attached. Please add it in plaintext encapsulated with 3x`

Dear sir,

I have attached the zip folder.

(Attachment error_dolfinx-mpc.rar is missing)

Dear Sir,

Sorry, am not able to attach the file. I have attached the drive link for the file.

https://drive.google.com/file/d/1SU5TxuW51jgJMM7o6B114XyQHtLs3rLr/view?usp=sharing

Regards,
GS

You have not attached the log for the c++ installation, i.e the output of:

Only the Python installation. I Need the output of these commands to be able to help you.

First, have you installed dolfinx?

Dear Sir,

Currently, I have Ubuntu 20.04 LTS, with WSL.
During the installation of dolfinx, when I execute the command: cmake -G Ninja cpp -B build-dir
I get the following error:
sadashivaiah@Guna:/mnt/f/dolfinx$ git checkout 0.1.0
HEAD is now at 95c6fcb896 Version c++ documentation (#1550)
sadashivaiah@Guna:/mnt/f/dolfinx$ cmake -G Ninja cpp -B build-dir
– Found Boost 1.71.0 at /usr/lib/x86_64-linux-gnu/cmake/Boost-1.71.0
– Requested configuration: QUIET REQUIRED COMPONENTS timer;filesystem
– Found boost_headers 1.71.0 at /usr/lib/x86_64-linux-gnu/cmake/boost_headers-1.71.0
– Found boost_timer 1.71.0 at /usr/lib/x86_64-linux-gnu/cmake/boost_timer-1.71.0
– [x] libboost_timer.so.1.71.0
– [ ] libboost_timer.a
– Adding boost_timer dependencies: chrono;headers
– Found boost_chrono 1.71.0 at /usr/lib/x86_64-linux-gnu/cmake/boost_chrono-1.71.0
– [x] libboost_chrono.so.1.71.0
– [ ] libboost_chrono.a
– Adding boost_chrono dependencies: headers
– Found boost_filesystem 1.71.0 at /usr/lib/x86_64-linux-gnu/cmake/boost_filesystem-1.71.0
– [x] libboost_filesystem.so.1.71.0
– [ ] libboost_filesystem.a
– Adding boost_filesystem dependencies: headers
CMake Error at CMakeLists.txt:156 (find_package):
By not providing “Findxtensor-blas.cmake” in CMAKE_MODULE_PATH this project
has asked CMake to find a package configuration file provided by
“xtensor-blas”, but CMake did not find one.

Could not find a package configuration file provided by “xtensor-blas” with
any of the following names:

xtensor-blasConfig.cmake
xtensor-blas-config.cmake

Add the installation prefix of “xtensor-blas” to CMAKE_PREFIX_PATH or set
“xtensor-blas_DIR” to a directory containing one of the above files. If
“xtensor-blas” provides a separate development package or SDK, be sure it
has been installed.

– Configuring incomplete, errors occurred!
See also “/mnt/f/dolfinx/build-dir/CMakeFiles/CMakeOutput.log”.

sadashivaiah@Guna:/mnt/f/dolfinx$

Regards,
GS

Is there a particular reason for choosing version 0.1.0, and not any of the later releases?

According to this output, you are missing xtensor-blas.
If you want a full install recipe for ubuntu 20.04 and v0.1.0, you should follow: dolfinx/Dockerfile at v0.1.0 · FEniCS/dolfinx · GitHub

I would strongly recommend you to use docker, or at least any of the later releases.