How to use Python to achieve the thresholding effect of the ‘Volumes’ module? (synchronized with the volume rendering)

Providing a link to where a solution was provided for @koeglfryderyk 's issue.