# After applying the threshold filter, the ParaView carshes

**URL:** https://discourse.paraview.org/t/after-applying-the-threshold-filter-the-paraview-carshes/8293
**Category:** ParaView Support
**Created:** [October 31, 2021, 11:46am UTC](https://discourse.paraview.org/t/after-applying-the-threshold-filter-the-paraview-carshes/8293 "2021-10-31T11:46:16Z")
**Posts on this page:** 10
**Page:** 1

<div class="post-metadata">

### Author: ![Rafeek\_Serhal](https://discourse.paraview.org/user_avatar/discourse.paraview.org/rafeek_serhal/32/7250_2.png) [@Rafeek\_Serhal](https://discourse.paraview.org/u/Rafeek_Serhal)
#### Post date: [October 31, 2021, 11:46am UTC](https://discourse.paraview.org/t/after-applying-the-threshold-filter-the-paraview-carshes/8293/1 "2021-10-31T11:46:16Z")

</div>

Hello,  
I have a question related to the Threshold Filter. I have this .vtp file. After, applying the “threshold filter” for the file, the ParaView crashes directly. Please, Can I know why the ParaView is crashing? My aim was to threshold the trajectories according to the principle stress array.

[block.vtp](https://discourse.paraview.org/uploads/short-url/4H4qt2X78uB3BigGwfIXckQfybX.vtp) (1.1 MB)

Thank you

---

<div class="post-metadata">

### Author: ![Tiffany\_Chhim](https://discourse.paraview.org/user_avatar/discourse.paraview.org/tiffany_chhim/32/10690_2.png) [@Tiffany\_Chhim](https://discourse.paraview.org/u/Tiffany_Chhim)
#### Post date: [November 2, 2021, 8:32am UTC](https://discourse.paraview.org/t/after-applying-the-threshold-filter-the-paraview-carshes/8293/3 "2021-11-02T08:32:42Z")

</div>

Hello Rafeek,

It seems the issue arises due to a bad definition of the lines in your data set, rather than due to the Threshold filter. Could you verify that you are generating those lines correctly?

---

<div class="post-metadata">

### Author: ![Rafeek\_Serhal](https://discourse.paraview.org/user_avatar/discourse.paraview.org/rafeek_serhal/32/7250_2.png) [@Rafeek\_Serhal](https://discourse.paraview.org/u/Rafeek_Serhal)
#### Post date: [November 3, 2021, 8:46pm UTC](https://discourse.paraview.org/t/after-applying-the-threshold-filter-the-paraview-carshes/8293/4 "2021-11-03T20:46:02Z")

</div>

Thank you for your reply,

The .vtp format is organized in away to have good visualization of the principle stresses tarjectoies. Please, can you tell me ,how the line definiton in the data set should be inorder to let the threshold filter works?

---

<div class="post-metadata">

### Author: ![Kenichiro-Yoshimi](https://discourse.paraview.org/letter_avatar_proxy/v4/letter/k/ecc23a/32.png) [@Kenichiro-Yoshimi](https://discourse.paraview.org/u/Kenichiro-Yoshimi)
#### Post date: [November 4, 2021, 12:04am UTC](https://discourse.paraview.org/t/after-applying-the-threshold-filter-the-paraview-carshes/8293/5 "2021-11-04T00:04:33Z")

</div>

It seems that Line elements consisting of a single node are not allowed. One solution is to use a duplicate nodal id to define the Line element for a single nodal point.  
[block\_dup\_ids.zip](https://discourse.paraview.org/uploads/short-url/oGEnCNjVlX5FhcLLpYnqSirGGn8.zip) (148.7 KB)

---

<div class="post-metadata">

### Author: ![Rafeek\_Serhal](https://discourse.paraview.org/user_avatar/discourse.paraview.org/rafeek_serhal/32/7250_2.png) [@Rafeek\_Serhal](https://discourse.paraview.org/u/Rafeek_Serhal)
#### Post date: [November 6, 2021, 9:03am UTC](https://discourse.paraview.org/t/after-applying-the-threshold-filter-the-paraview-carshes/8293/6 "2021-11-06T09:03:02Z")

</div>

@Kenichiro-Yoshimi Perfect!. Thank you for this valuable information. Please, can you tell me which method or algorithm or skill you used to duplicate nodal id to define the Line element for a single nodal point?

---

<div class="post-metadata">

### Author: ![Kenichiro-Yoshimi](https://discourse.paraview.org/letter_avatar_proxy/v4/letter/k/ecc23a/32.png) [@Kenichiro-Yoshimi](https://discourse.paraview.org/u/Kenichiro-Yoshimi)
#### Post date: [November 6, 2021, 9:55am UTC](https://discourse.paraview.org/t/after-applying-the-threshold-filter-the-paraview-carshes/8293/7 "2021-11-06T09:55:26Z")

</div>

I created a very trivial Python script just for this purpose.  
[duplicate\_ids.py](https://discourse.paraview.org/uploads/short-url/rmVFVHtvqraLBckslsbMBQrB87U.py) (1.2 KB)

---

<div class="post-metadata">

### Author: ![Rafeek\_Serhal](https://discourse.paraview.org/user_avatar/discourse.paraview.org/rafeek_serhal/32/7250_2.png) [@Rafeek\_Serhal](https://discourse.paraview.org/u/Rafeek_Serhal)
#### Post date: [November 6, 2021, 5:53pm UTC](https://discourse.paraview.org/t/after-applying-the-threshold-filter-the-paraview-carshes/8293/8 "2021-11-06T17:53:41Z")

</div>

Thank you for your effort.

---

<div class="post-metadata">

### Author: ![Rafeek\_Serhal](https://discourse.paraview.org/user_avatar/discourse.paraview.org/rafeek_serhal/32/7250_2.png) [@Rafeek\_Serhal](https://discourse.paraview.org/u/Rafeek_Serhal)
#### Post date: [November 13, 2021, 9:08am UTC](https://discourse.paraview.org/t/after-applying-the-threshold-filter-the-paraview-carshes/8293/9 "2021-11-13T09:08:54Z")

</div>

[volume.rar](https://discourse.paraview.org/uploads/short-url/4veI06NjkAB4W8SpZwKTb05CMnC.rar) (525.0 KB)

Hello,

Also now I am facing the same problem with this .vtp file, where the Paraviw is crushing after using the Threshold filter. In this .vtp I duplicated nodal id to define the Line element for a single nodal point as you mentioned . However, the Threshold filter is still not working.Please , can I know why the Threshold filter is not working?

Thank You

---

<div class="post-metadata">

### Author: ![Kenichiro-Yoshimi](https://discourse.paraview.org/letter_avatar_proxy/v4/letter/k/ecc23a/32.png) [@Kenichiro-Yoshimi](https://discourse.paraview.org/u/Kenichiro-Yoshimi)
#### Post date: [November 13, 2021, 5:39pm UTC](https://discourse.paraview.org/t/after-applying-the-threshold-filter-the-paraview-carshes/8293/10 "2021-11-13T17:39:00Z")

</div>

Hello,

Now there are empty line elements in the data. You need to avoid outputting empty line elements, or remove them afterwards. Below is the vtp file with the empty line elements removed and the script used to do so.  
[volume\_dup\_ids.7z](https://discourse.paraview.org/uploads/short-url/3x8p8Aj5VsqHYj4ChqzFUGHViSE.7z) (323.5 KB)  
[duplicate\_ids.py](https://discourse.paraview.org/uploads/short-url/aqgPYkiR054Hmd9UjZoNlKo2A79.py) (2.0 KB)

---

<div class="post-metadata">

### Author: ![Rafeek\_Serhal](https://discourse.paraview.org/user_avatar/discourse.paraview.org/rafeek_serhal/32/7250_2.png) [@Rafeek\_Serhal](https://discourse.paraview.org/u/Rafeek_Serhal)
#### Post date: [November 14, 2021, 3:23pm UTC](https://discourse.paraview.org/t/after-applying-the-threshold-filter-the-paraview-carshes/8293/11 "2021-11-14T15:23:59Z")

</div>

Thank you for your effort.
