# \#python

**URL:** https://discourse.vtk.org/tag/python/6.md

[Latest](https://discourse.vtk.org/latest.md) · [Categories](https://discourse.vtk.org/categories.md) · [Tags](https://discourse.vtk.org/tags.md)

---

## [vtkXOpenGLRenderWindow::DestroyWindow() can deadlock when Finalize() runs from QVTKRenderWindowInteractor.closeEvent()](https://discourse.vtk.org/t/vtkxopenglrenderwindow-destroywindow-can-deadlock-when-finalize-runs-from-qvtkrenderwindowinteractor-closeevent/16515)

<div class="topic-metadata">

**Author:** [@DungTruog](https://discourse.vtk.org/u/DungTruog)\
**Replies:** 1\
**Last updated:** [September 17, 2026, 6:52pm UTC](https://discourse.vtk.org/t/vtkxopenglrenderwindow-destroywindow-can-deadlock-when-finalize-runs-from-qvtkrenderwindowinteractor-closeevent/16515 "2026-09-17T18:52:37Z")

</div>

We meet an intermittent SIGSEGV on closing a Qt window that embeds \`QVTKRenderWindowInteractor\`. Confirmed via a core-dump backtrace and by reading \`vtkXOpenGLRenderWindow\`: the vendored interactor only finalizes its ren…

---

## [Trouble in pip installing vtk-osmesa](https://discourse.vtk.org/t/trouble-in-pip-installing-vtk-osmesa/14890)

<div class="topic-metadata">

**Author:** [@natsu\_mizu](https://discourse.vtk.org/u/natsu_mizu)\
**Replies:** 22\
**Last updated:** [September 15, 2026, 1:53am UTC](https://discourse.vtk.org/t/trouble-in-pip-installing-vtk-osmesa/14890 "2026-09-15T01:53:05Z")

</div>

I’ve been using vtk-osmesa installed with pip as pip install --extra-index-url https://wheels.vtk.org vtk-osmesa, following this post: Status Update: VTK Python Wheels - Announcements - VTK OS: “Rocky Linux 8.6 (Green …

---

## [Line elements cause missing edges in triangle cells](https://discourse.vtk.org/t/line-elements-cause-missing-edges-in-triangle-cells/16521)

<div class="topic-metadata">

**Author:** [@raungst](https://discourse.vtk.org/u/raungst)\
**Replies:** 5\
**Last updated:** [September 4, 2026, 7:54pm UTC](https://discourse.vtk.org/t/line-elements-cause-missing-edges-in-triangle-cells/16521 "2026-09-04T19:54:53Z")

</div>

This started in VTK 9.6, but is present in 9.7 as well. I’m not sure how pervasive it is, but if I have an unstructured grid with only triangles and lines, the triangles don’t have edges shown. If I don’t have the lines,…

---

## [Mismatch of points/tuples between vtkmCleanGrid and its VTK-numpy-wrapper](https://discourse.vtk.org/t/mismatch-of-points-tuples-between-vtkmcleangrid-and-its-vtk-numpy-wrapper/16517)

<div class="topic-metadata">

**Author:** [@Bodacious](https://discourse.vtk.org/u/Bodacious)\
**Replies:** 1\
**Last updated:** [August 25, 2026, 4:13pm UTC](https://discourse.vtk.org/t/mismatch-of-points-tuples-between-vtkmcleangrid-and-its-vtk-numpy-wrapper/16517 "2026-08-25T16:13:14Z")

</div>

Hello, This post is a repost of https://discourse.paraview.org/t/mismatch-of-points-tuples-between-vtkmcleangrid-and-its-vtk-numpy-wrapper/17698?u=bodacious after @mwestphal proposition. I have a vtkUnstructuredGrid dat…

---

## [VR updates, some fun demos and a few questions](https://discourse.vtk.org/t/vr-updates-some-fun-demos-and-a-few-questions/16502)

<div class="topic-metadata">

**Author:** [@fraseyboo](https://discourse.vtk.org/u/fraseyboo)\
**Replies:** 5\
**Last updated:** [August 4, 2026, 3:58pm UTC](https://discourse.vtk.org/t/vr-updates-some-fun-demos-and-a-few-questions/16502 "2026-08-04T15:58:33Z")

</div>

So the VR functionalities of VTK have always been a bit under realised and so I thought I’d make a quick demo video of the 3D widgets VTK uses working in VR, I implemented an in-VR menu that attaches to the controllers a…

---

## [Issue with QVTKRenderWindowInteractor and PySide6 6.10.1 on MacOS](https://discourse.vtk.org/t/issue-with-qvtkrenderwindowinteractor-and-pyside6-6-10-1-on-macos/16225)

<div class="topic-metadata">

**Author:** [@nchampag](https://discourse.vtk.org/u/nchampag)\
**Replies:** 16\
**Last updated:** [July 14, 2026, 3:06pm UTC](https://discourse.vtk.org/t/issue-with-qvtkrenderwindowinteractor-and-pyside6-6-10-1-on-macos/16225 "2026-07-14T15:06:45Z")

</div>

The issue is code with QVTKRenderWindowInteractor on macOS that worked with VTK 9.4.2 and PySide6 6.9.3 fails to display anything after updating to PySide 6.10.1. No error message is displayed–it just hangs. Pressing c…

---

## [How to propagate non-VTK data in the pipeline in a simple way?](https://discourse.vtk.org/t/how-to-propagate-non-vtk-data-in-the-pipeline-in-a-simple-way/16472)

<div class="topic-metadata">

**Author:** [@CsatiZoltan](https://discourse.vtk.org/u/CsatiZoltan)\
**Replies:** 4\
**Last updated:** [June 23, 2026, 10:50pm UTC](https://discourse.vtk.org/t/how-to-propagate-non-vtk-data-in-the-pipeline-in-a-simple-way/16472 "2026-06-23T22:50:53Z")

</div>

I have a ParaView reader plugin in Python, which stores the path to the opened file. I want to implement various operations on the file that was read by the reader. So I write one filter for each operation. This way, I h…

---

## [Calculate slope of surface elevation](https://discourse.vtk.org/t/calculate-slope-of-surface-elevation/16458)

<div class="topic-metadata">

**Author:** [@albgabor](https://discourse.vtk.org/u/albgabor)\
**Replies:** 1\
**Last updated:** [June 16, 2026, 7:42am UTC](https://discourse.vtk.org/t/calculate-slope-of-surface-elevation/16458 "2026-06-16T07:42:13Z")

</div>

Hi all, I’m trying to calculate the slope(s) of a 3D surface. Specifically I am working on some wind simulations over wavy surfaces, where I can extract some variables (velocities and pressure) from the simulation at t…

---

## [unexpected behavior when selecting (and "highlighting") cells in trame](https://discourse.vtk.org/t/unexpected-behavior-when-selecting-and-highlighting-cells-in-trame/10333)

<div class="topic-metadata">

**Author:** [@Robert\_Collar](https://discourse.vtk.org/u/Robert_Collar)\
**Replies:** 8\
**Last updated:** [May 7, 2026, 4:16am UTC](https://discourse.vtk.org/t/unexpected-behavior-when-selecting-and-highlighting-cells-in-trame/10333 "2026-05-07T04:16:18Z")

</div>

Hi VTK Community! I’m attempting to adapt the selection highlighting functionality used in this trame example, but the exhibited behavior is unexpected. I’m trying to select cells in a vtkPolyData Object consisting of a …

---

## [Multiple viewports and LIC surfaces](https://discourse.vtk.org/t/multiple-viewports-and-lic-surfaces/16398)

<div class="topic-metadata">

**Author:** [@Carlos\_Montilla](https://discourse.vtk.org/u/Carlos_Montilla)\
**Replies:** 4\
**Last updated:** [April 28, 2026, 8:02pm UTC](https://discourse.vtk.org/t/multiple-viewports-and-lic-surfaces/16398 "2026-04-28T20:02:07Z")

</div>

Hello, I am trying to build a split view configuration using a single vtkRenderWindow and multiple viewports. Each viewport should render a different dataset using a SurfaceLICMapper, however only the bottom left pane s…

---

## [Stop generating vtk wheel for Python 3.8 and 3.9](https://discourse.vtk.org/t/stop-generating-vtk-wheel-for-python-3-8-and-3-9/16090)

<div class="topic-metadata">

**Author:** [@lgivord](https://discourse.vtk.org/u/lgivord)\
**Replies:** 4\
**Last updated:** [April 22, 2026, 6:26am UTC](https://discourse.vtk.org/t/stop-generating-vtk-wheel-for-python-3-8-and-3-9/16090 "2026-04-22T06:26:20Z")

</div>

Hello everyone, As the Python version 3.8 is end of life since one year, we plan to stop generating VTK wheel for this version. Additionally, once Python 3.9 will be end of life at the end of this month, we will also r…

---

## [Apply scalar in vtkDijkstraGraphGeodesicPath function](https://discourse.vtk.org/t/apply-scalar-in-vtkdijkstragraphgeodesicpath-function/16374)

<div class="topic-metadata">

**Author:** [@joo94372](https://discourse.vtk.org/u/joo94372)\
**Replies:** 0\
**Last updated:** [April 7, 2026, 10:38am UTC](https://discourse.vtk.org/t/apply-scalar-in-vtkdijkstragraphgeodesicpath-function/16374 "2026-04-07T10:38:00Z")

</div>

Hello. I’m using it well to find a distance-based path for the vtkDijkstraGraphGeodesicPath function. But I want to find a path that moves close based on the desired curvature value. The VTK: vtkDijkstraGraphGeodesicPa…

---

## [How to overlay a vector field on a molecule, with output to file for use in ParaView](https://discourse.vtk.org/t/how-to-overlay-a-vector-field-on-a-molecule-with-output-to-file-for-use-in-paraview/16357)

<div class="topic-metadata">

**Author:** [@jzwanzig](https://discourse.vtk.org/u/jzwanzig)\
**Replies:** 0\
**Last updated:** [March 25, 2026, 2:10pm UTC](https://discourse.vtk.org/t/how-to-overlay-a-vector-field-on-a-molecule-with-output-to-file-for-use-in-paraview/16357 "2026-03-25T14:10:46Z")

</div>

Hello, I am generating vector field data in an ab initio physics code, and I am able to convert it to a vtkStructuredGrid and display it nicely in ParaView; I am also able to generate a vtkMolecule and display that nicel…

---

## [Trame + WASM: bind custom widget](https://discourse.vtk.org/t/trame-wasm-bind-custom-widget/16350)

<div class="topic-metadata">

**Author:** [@kerim](https://discourse.vtk.org/u/kerim)\
**Replies:** 3\
**Last updated:** [March 23, 2026, 9:37am UTC](https://discourse.vtk.org/t/trame-wasm-bind-custom-widget/16350 "2026-03-23T09:37:42Z")

</div>

Hi, I wrote custom widget in C++ fork of VTK 9.6 and now I’m trying to port it to Trame local view using WASM approach. My approach is to build VTK WASM, install trame-vtklocal package with VTK\_WASM\_DIR\_OVERRIDE env va…

---

## [Python error vtkXOpenGLRenderWindow Could not find a decent config](https://discourse.vtk.org/t/python-error-vtkxopenglrenderwindow-could-not-find-a-decent-config/15992)

<div class="topic-metadata">

**Author:** [@marpoleSim](https://discourse.vtk.org/u/marpoleSim)\
**Replies:** 9\
**Last updated:** [March 19, 2026, 12:01pm UTC](https://discourse.vtk.org/t/python-error-vtkxopenglrenderwindow-could-not-find-a-decent-config/15992 "2026-03-19T12:01:39Z")

</div>

This is the first time I use python to run vtk. I got the following errors when the code ran to the following line. renderWindow = vtkRenderWindow() The error message is, 2025-08-22 11:11:25.167 ( 0.546s) \[ 75B0D…

---

## [vtkChartXY is rendered only in VtkRemoteView](https://discourse.vtk.org/t/vtkchartxy-is-rendered-only-in-vtkremoteview/16317)

<div class="topic-metadata">

**Author:** [@Muhammed\_Ali](https://discourse.vtk.org/u/Muhammed_Ali)\
**Replies:** 2\
**Last updated:** [March 7, 2026, 12:50am UTC](https://discourse.vtk.org/t/vtkchartxy-is-rendered-only-in-vtkremoteview/16317 "2026-03-07T00:50:41Z")

</div>

I’m trying to make a 2d plot to run in the browser, but it gets rendered only in VtkRemoteView mode in VtkLocalView it shows just white blank screen and prints Gtk-Message: 03:45:36.722: Not loading module “atk-bridg…

---

## [Yet more simple python API](https://discourse.vtk.org/t/yet-more-simple-python-api/16279)

<div class="topic-metadata">

**Author:** [@berk.geveci](https://discourse.vtk.org/u/berk.geveci)\
**Replies:** 12\
**Last updated:** [March 2, 2026, 10:33am UTC](https://discourse.vtk.org/t/yet-more-simple-python-api/16279 "2026-03-02T10:33:43Z")

</div>

Hi folks, Over this weekend, I prototyped another layer of simple python interface that is a lot closer to pyvista and vedo. Here is a description: The functional and postfix part are super easy to implement and main…

---

## [vtkAxesActor bounding box appears to be affected by it's world position](https://discourse.vtk.org/t/vtkaxesactor-bounding-box-appears-to-be-affected-by-its-world-position/16290)

<div class="topic-metadata">

**Author:** [@Dan\_The\_Man](https://discourse.vtk.org/u/Dan_The_Man)\
**Replies:** 4\
**Last updated:** [February 20, 2026, 4:59pm UTC](https://discourse.vtk.org/t/vtkaxesactor-bounding-box-appears-to-be-affected-by-its-world-position/16290 "2026-02-20T16:59:35Z")

</div>

First noticed and described in this comment I have asked AI to provide a test script that can replicate the behavior I’m seeing in my larger application. Here’s the prompt I gave claude.ai for completeness: I’m lookin…

---

## [vtk python doesn't support get key PgUp/PgDn](https://discourse.vtk.org/t/vtk-python-doesnt-support-get-key-pgup-pgdn/16284)

<div class="topic-metadata">

**Author:** [@Nam\_Le\_Hoang](https://discourse.vtk.org/u/Nam_Le_Hoang)\
**Replies:** 2\
**Last updated:** [February 12, 2026, 6:38am UTC](https://discourse.vtk.org/t/vtk-python-doesnt-support-get-key-pgup-pgdn/16284 "2026-02-12T06:38:05Z")

</div>

Hi, I’m using \`vtk==9.5.0\` with python in PySide2. Below is my simple script that I try to catch user key press and do works. But when I type PgUp PgDn the GetKeySym return None . Just wanna know if vtk doesn’t support i…

---

## [find\_package(VTK REQUIRED) refuses to load](https://discourse.vtk.org/t/find-package-vtk-required-refuses-to-load/16271)

<div class="topic-metadata">

**Author:** [@Richard\_Spencer](https://discourse.vtk.org/u/Richard_Spencer)\
**Replies:** 3\
**Last updated:** [February 4, 2026, 4:12pm UTC](https://discourse.vtk.org/t/find-package-vtk-required-refuses-to-load/16271 "2026-02-04T16:12:48Z")

</div>

I am using CMake 4.4.2 in order to use Visual Studio 18 2026 supported since 4.2. I am building CompuCell3D from source. Why is it finding VTK 9.4.2 but refusing to use it? How do I work around this apparent CMake pro…

---

## [Partitioning large meshes with uneven cell distribution](https://discourse.vtk.org/t/partitioning-large-meshes-with-uneven-cell-distribution/16241)

<div class="topic-metadata">

**Author:** [@PathosV](https://discourse.vtk.org/u/PathosV)\
**Replies:** 0\
**Last updated:** [January 18, 2026, 7:07pm UTC](https://discourse.vtk.org/t/partitioning-large-meshes-with-uneven-cell-distribution/16241 "2026-01-18T19:07:27Z")

</div>

I’m trying to find a partitioning method that can scale for large unstructured meshes. I need to support mesh sizes that can be several hundred million cells. I’m aware of vtkRedistributeDataSetFilter, and I’ve accessed…

---

## [vtkGLTFWriter: a working example?](https://discourse.vtk.org/t/vtkgltfwriter-a-working-example/11620)

<div class="topic-metadata">

**Author:** [@bistek](https://discourse.vtk.org/u/bistek)\
**Replies:** 6\
**Last updated:** [January 15, 2026, 8:20am UTC](https://discourse.vtk.org/t/vtkgltfwriter-a-working-example/11620 "2026-01-15T08:20:43Z")

</div>

Hello, does anybody have a working example of vtkGLTFWriter(). The documentation is very concise, and I’m trying different patterns similar to other writers, but I always get the error: Process finished with exit code …

---

## [vtkOpenGLRenderWindow failed with pyinstaller](https://discourse.vtk.org/t/vtkopenglrenderwindow-failed-with-pyinstaller/16204)

<div class="topic-metadata">

**Author:** [@BotellaA](https://discourse.vtk.org/u/BotellaA)\
**Replies:** 11\
**Last updated:** [January 12, 2026, 7:21pm UTC](https://discourse.vtk.org/t/vtkopenglrenderwindow-failed-with-pyinstaller/16204 "2026-01-12T19:21:05Z")

</div>

I have a Python VTK app working on Linux. I am trying to use pyinstaller to package the app for distribution. Once the app is packaged, I got this error: 2025-12-31 08:42:19.054 ( 2.472s) \[ 70800EFF9080\]vtkXOpenGLR…

---

## [Changing the axis colors in vtkCameraOrientationWidget](https://discourse.vtk.org/t/changing-the-axis-colors-in-vtkcameraorientationwidget/14664)

<div class="topic-metadata">

**Author:** [@Connor9220](https://discourse.vtk.org/u/Connor9220)\
**Replies:** 3\
**Last updated:** [January 12, 2026, 2:01pm UTC](https://discourse.vtk.org/t/changing-the-axis-colors-in-vtkcameraorientationwidget/14664 "2026-01-12T14:01:17Z")

</div>

The AXIS colors in the vtkCameraOrientationWidget are non standard, and I can’t figure out how to change them. Doesn’t look like there is a way to do this? Help?

---

## [Python type hints](https://discourse.vtk.org/t/python-type-hints/16213)

<div class="topic-metadata">

**Author:** [@BotellaA](https://discourse.vtk.org/u/BotellaA)\
**Replies:** 1\
**Last updated:** [January 7, 2026, 1:24pm UTC](https://discourse.vtk.org/t/python-type-hints/16213 "2026-01-07T13:24:23Z")

</div>

You provide all the stub files for the VTK C++ objects, but I cannot find the type hints or stub files for the Python files in the web module: https://gitlab.kitware.com/vtk/vtk/-/tree/master/Web/Python/vtkmodules/web I…

---

## [pixelated artifacts in native vtk implementation compared to pyvista](https://discourse.vtk.org/t/pixelated-artifacts-in-native-vtk-implementation-compared-to-pyvista/16207)

<div class="topic-metadata">

**Author:** [@jonaspleyer](https://discourse.vtk.org/u/jonaspleyer)\
**Replies:** 2\
**Last updated:** [January 5, 2026, 1:40pm UTC](https://discourse.vtk.org/t/pixelated-artifacts-in-native-vtk-implementation-compared-to-pyvista/16207 "2026-01-05T13:40:11Z")

</div>

Hey everyone, I am having trouble, figuring out the reason for why I am seeing pixelated artifacts in one of my renders. I have a pipline which works well for my purpose and is implemented in pyvista. I wanted to recrea…

---

## [VTK build fails on Windows when Python type hints are requested (VTK\_BUILD\_PYI\_FILES)](https://discourse.vtk.org/t/vtk-build-fails-on-windows-when-python-type-hints-are-requested-vtk-build-pyi-files/16192)

<div class="topic-metadata">

**Author:** [@scotsman60](https://discourse.vtk.org/u/scotsman60)\
**Replies:** 2\
**Last updated:** [December 22, 2025, 3:24pm UTC](https://discourse.vtk.org/t/vtk-build-fails-on-windows-when-python-type-hints-are-requested-vtk-build-pyi-files/16192 "2025-12-22T15:24:36Z")

</div>

Hello, I’m building VTK 9.5.2 on Windows and all is well until I request Python type hints with VTK\_BUILD\_PYI\_FILES. The build fails with the following error Severity Code Description Project File Line Suppression Sta…

---

## [Looking for guidance on writing python unit tests using python vtk](https://discourse.vtk.org/t/looking-for-guidance-on-writing-python-unit-tests-using-python-vtk/16148)

<div class="topic-metadata">

**Author:** [@Dan\_The\_Man](https://discourse.vtk.org/u/Dan_The_Man)\
**Replies:** 8\
**Last updated:** [November 24, 2025, 5:03pm UTC](https://discourse.vtk.org/t/looking-for-guidance-on-writing-python-unit-tests-using-python-vtk/16148 "2025-11-24T17:03:42Z")

</div>

I am developing a python-VTK application and am noticing some unusual behavior in python unittest-based tests I am building alongside my application. I have noticed that tests that are defined in separate suites appear t…

---

## [Incorrect cell\_data shapes when reading .cas.h5 with vtkFLUENTCFFReader](https://discourse.vtk.org/t/incorrect-cell-data-shapes-when-reading-cas-h5-with-vtkfluentcffreader/16153)

<div class="topic-metadata">

**Author:** [@nmheim](https://discourse.vtk.org/u/nmheim)\
**Replies:** 4\
**Last updated:** [November 20, 2025, 10:12am UTC](https://discourse.vtk.org/t/incorrect-cell-data-shapes-when-reading-cas-h5-with-vtkfluentcffreader/16153 "2025-11-20T10:12:27Z")

</div>

Hey everyone! This is my first post here, so I apologize if its in the wrong category or otherwise not according to the rules. Happy to open this in a different place, if that helps:) I am encountering an issue when rea…

---

## [how to adjust gl\_pointSize when zoom in/out](https://discourse.vtk.org/t/how-to-adjust-gl-pointsize-when-zoom-in-out/16137)

<div class="topic-metadata">

**Author:** [@Nam\_Le\_Hoang](https://discourse.vtk.org/u/Nam_Le_Hoang)\
**Replies:** 0\
**Last updated:** [November 12, 2025, 3:50am UTC](https://discourse.vtk.org/t/how-to-adjust-gl-pointsize-when-zoom-in-out/16137 "2025-11-12T03:50:53Z")

</div>

Hi everyone, I have a problem need the support. I’m using vtk with python using vtkInteractorStyleTrackballCamera with the setting \`\` self.interactor\_style = vtk.vtkInteractorStyleTrackballCamera() self.interactor.Se…

[Next page](https://discourse.vtk.org/tag/python/6.md?match_all_tags=true&page=1&tags%5B%5D=python)
