# pvpython script to convert binary Legacy VTK file to some compressed version to reduce file size

**URL:** https://discourse.paraview.org/t/pvpython-script-to-convert-binary-legacy-vtk-file-to-some-compressed-version-to-reduce-file-size/3595
**Category:** ParaView Support
**Tags:** python, vtk
**Created:** [February 18, 2020, 8:44pm UTC](https://discourse.paraview.org/t/pvpython-script-to-convert-binary-legacy-vtk-file-to-some-compressed-version-to-reduce-file-size/3595 "2020-02-18T20:44:00Z")
**Posts on this page:** 1
**Showing post:** 10

<div class="post-metadata">

### Author: ![mwestphal](https://discourse.paraview.org/user_avatar/discourse.paraview.org/mwestphal/32/17_2.png) [@mwestphal](https://discourse.paraview.org/u/mwestphal)
#### Post date: [April 27, 2020, 2:28am UTC](https://discourse.paraview.org/t/pvpython-script-to-convert-binary-legacy-vtk-file-to-some-compressed-version-to-reduce-file-size/3595/10 "2020-04-27T02:28:11Z")

</div>

> [@How to figure out a python code using the python trace mechanism](https://discourse.paraview.org/t/how-to-figure-out-a-python-code-using-the-python-trace-mechanism/4186):
>
> Starting to use the python shell and pvpython can be overwhelming sometimes as it can be hard to figure out how to implement what you are looking to do using only python, even with the [documentation](https://kitware.github.io/paraview-docs/latest/python/). Here is a simple solution, the “python trace” mechanism. As its name indicate, the python trace let you trace your action in the UI to create a python script. Here is how I’d recommend to use it. Write your pvpython code until you reach a point of not knowing how to do a specific task in python…

---

_[View the full topic](https://discourse.paraview.org/t/pvpython-script-to-convert-binary-legacy-vtk-file-to-some-compressed-version-to-reduce-file-size/3595)._
