Skip to content

tp.bandpass issues #793

@jab-cmd

Description

@jab-cmd

Hi,

I've come across two issues regarding the function bandpass of trackpy.

The first one is regarding the function vectorization.
Basically, when I use it directly on a numpy array of images without using a loop, the first images of the stack and the last one are completely black, meaning, almost every pixels is somehow clipped to 0. Only a few are at a certain random value(i.e 10 or 15 pixels out of 1024*1024). (I am working on 8bits images, each pixel ranging from 0 to 255 in value). This issue resolves itself when I use a loop in order to process the stack.

ephem=tp.bandpass(ephem, l_short, l_long, trshold)
-> First and last images are lost

vs

 for i in range(len(ephem)):
     ephem[i]=tp.bandpass(ephem[i], l_short, l_long, trshold) 

-> Every images are intact

The second situation regarding this function is about its version. I applied the current version of the function and the version from the v0.3x release on the same stack of images, with the same parameters (llong, lshort etc...) and got way better results with the version from 8 years ago. I know both versions are not going to do the exact same thing, but it looks like the new version is worse.

FIrst image is after use of tp.bandpass from latest release.
Image
Second image is after use of tp.bandpass from release v03.x
Image

parameters used : lshort =1,llong=5, threshold = 1
As you can see, the version from the old release looks smoother, cleaner. This results in a better tracking for us afterwards.
I would expect a newer release to be better...
What do you guys think ? Would love to have insights regarding this.

Thank you.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions