Skip to content

Commit ac09d10

Browse files
authored
Merge pull request #1267 from nschloe/convert-fix
Convert fix
2 parents 3e6bdf5 + 0bd7831 commit ac09d10

File tree

4 files changed

+9
-4
lines changed

4 files changed

+9
-4
lines changed

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313

1414
<!--[![PyPi downloads](https://img.shields.io/pypi/dm/meshio.svg?style=flat-square)](https://pypistats.org/packages/meshio)-->
1515

16-
[![Discord](https://img.shields.io/static/v1?logo=discord&label=chat&message=on%20discord&color=7289da&style=flat-square)](https://discord.gg/Z6DMsJh4Hr)
16+
[![Discord](https://img.shields.io/static/v1?logo=discord&logoColor=white&label=chat&message=on%20discord&color=7289da&style=flat-square)](https://discord.gg/Z6DMsJh4Hr)
1717

1818
[![gh-actions](https://img.shields.io/github/workflow/status/nschloe/meshio/ci?style=flat-square)](https://github.com/nschloe/meshio/actions?query=workflow%3Aci)
1919
[![codecov](https://img.shields.io/codecov/c/github/nschloe/meshio.svg?style=flat-square)](https://app.codecov.io/gh/nschloe/meshio)

setup.cfg

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[metadata]
22
name = meshio
3-
version = 5.2.5
3+
version = 5.2.6
44
author = Nico Schlömer et al.
55
author_email = [email protected]
66
description = I/O for many mesh formats

src/meshio/_cli/_convert.py

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -56,10 +56,14 @@ def convert(args):
5656
mesh.points = np.ascontiguousarray(mesh.points)
5757

5858
if args.sets_to_int_data:
59-
mesh.sets_to_int_data()
59+
mesh.point_sets_to_data()
60+
mesh.cell_sets_to_data()
6061

6162
if args.int_data_to_sets:
62-
mesh.int_data_to_sets()
63+
for key in mesh.point_data:
64+
mesh.point_data_to_sets(key)
65+
for key in mesh.cell_data:
66+
mesh.cell_data_to_sets(key)
6367

6468
# write it out
6569
kwargs = {"file_format": args.output_format}

tests/test_cli.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,7 @@ def test_convert(tmp_path):
3636
"gmsh",
3737
"--output-format",
3838
"vtk",
39+
"--sets-to-int-data",
3940
]
4041
)
4142

0 commit comments

Comments
 (0)