ome / omero-scripts

Core OMERO Scripts
https://pypi.org/project/omero-scripts/
12 stars 32 forks source link

Fix time Increment issues #117

Closed bramalingam closed 7 years ago

bramalingam commented 8 years ago

ref: http://trac.openmicroscopy.org/ome/ticket/13157

Issue: If no time increment is provided, Kymograph script produces an image where pixel Size X is set, but pixel Size Y is not set.

Fix: Sets a default value for time_increment parameter (pixel size Y) and warns the user about the default time_increment value in the log

Testing instructions: Run the script on the following image on Squig: ome/team/Balaji/Omero.Scripts_Issue/33676-EB1 dsRed (red) tracking along peripheral SEPT2-YFP filaments (green). Spinning disc confocal microscopy..ome.tiff

Once the kymograph script is completed: Please check the logs for the following message: "Metadata does not contain Time Increment parameter: Please manually set this value to get accurate estimate of the kinetics" "Default value set : Time_Increment = 1 sec/frame"

And Run the Kymograph_Analysis script and check: i) If it does throw an exception (Without this PR, the kymograph_analysis script should throw an exception) ii) If the resultant csv is properly attached to the image and check if the csv opens/makes sense.

@dominikl @will-moore @pwalczysko

dominikl commented 8 years ago

Would it also make sense to add a default value to the script parameter description? https://github.com/bramalingam/scripts/blob/bb72b96b9cb518a480e89581a6e29b59e3df8e7c/omero/analysis_scripts/Kymograph.py#L523

dominikl commented 8 years ago

Sorry, wanted to test it locally, but got an error (but guess that's only a problem of my local installation)

  File "/Users/dlindner/Repositories/openmicroscopy/dist/lib/python/omero/gateway/__init__.py", line 3418, in createImageFromNumpySeq
    raise exc
NotImplementedError: fromstring() has been removed. Please call frombytes() instead.
will-moore commented 8 years ago

I think you need to use Pillow 2.9.x. See https://trello.com/c/jZjPZf8K/637-attributeerror-numpy-ndarray-object-has-no-attribute-tobytes

dominikl commented 8 years ago

Thanks @will-moore and @aleksandra-tarkowska , after downgrading my local pillow to 2.9 the script works. Also fixed the error related to the missing y pixel size 👍

pwalczysko commented 8 years ago

This have failed checks. Postpponing the review. @bramalingam

sbesson commented 8 years ago

Closed/reopened now Travis should be fixed via #118

joshmoore commented 8 years ago

Still having flake8 issues on Kymograph.

jburel commented 7 years ago

@bramalingam what do you want to do this PR?

jburel commented 7 years ago

Closing this PR for now. @bramalingam to re-open it when ready