Notice: In order to edit this ticket you need to be either: a Product Owner, The owner or the reporter of the ticket, or, in case of a Task not yet assigned, a team_member"

Task #7306 (closed)

Opened 8 years ago

Closed 8 years ago

Last modified 8 years ago

BUG: param range miscalculated

Reported by: atarkowska Owned by: wmoore
Priority: critical Milestone: OMERO-4.4
Component: Scripting Version: n.a.
Keywords: n.a. Cc: jburel
Resources: n.a. Referenced By: n.a.
References: n.a. Remaining Time: 0.0d
Sprint: 2011-12-13 (4)

Description (last modified by atarkowska)

Referring to #7305 script misinterpret range values when they are set to '0'. The problem is in calculateRanges where commandArgs "T_End" and "Z_End" is 0 is treated as entire range rather then particular plane. Giving commandArgs= {"Z_Start":0, "Z_End":0,"T_Start": 1, "T_End": 5} will make movie for entire Z range and T in (1-5) rather then generate movie for first plane and T in (1-5)

Instead of:

if "Z_Start" in commandArgs and commandArgs["Z_Start"] = 0 and commandArgs["Z_Start"] < sizeZ:
        zStart = commandArgs["Z_Start"]
if "Z_End" in commandArgs and commandArgs["Z_End"] = 0 and commandArgs["Z_End"] < sizeZ:
        zEnd = commandArgs["Z_End"]+1

should be:

if "Z_Start" in commandArgs and commandArgs["Z_Start"] >= 0 and commandArgs["Z_Start"] < sizeZ:
        zStart = commandArgs["Z_Start"]
if "Z_End" in commandArgs and commandArgs["Z_End"] >= 0 and commandArgs["Z_End"] < sizeZ:
        zEnd = commandArgs["Z_End"]+1

Change History (8)

comment:1 Changed 8 years ago by atarkowska

  • Summary changed from BUG to BUG: param range miscalculated

comment:2 Changed 8 years ago by atarkowska

  • Cc jburel added
  • Description modified (diff)

comment:3 Changed 8 years ago by atarkowska

  • Description modified (diff)

comment:4 Changed 8 years ago by jburel

The script was initially only used from the viewer where the default z (resp. t) was used to set the plane. Now that we use it from other location it makes sense to adjust.
Changing the logic of the script is valid but we will have to announce it when we release so we reduce the impact.
I will review that when I come back.

You should have a scripts review sprint (e.g. #7102) to improve error handling and parameters check.

comment:5 Changed 8 years ago by jmoore

  • Sprint changed from 2011-11-29 (3) to 2011-12-13 (4)

Moved from sprint 2011-11-29 (3)

comment:6 Changed 8 years ago by wmoore

  • Status changed from new to accepted

comment:7 Changed 8 years ago by wmoore

  • Resolution set to fixed
  • Status changed from accepted to closed

comment:8 Changed 8 years ago by Will Moore <will@…>

  • Remaining Time set to 0

(In [bb4b28074f10fadf502d3e0f1a8e6c25d9a40743/ome.git] on branch develop) Fix Z/T ranges in Make_Movie.py. Closes #7306

Note: See TracTickets for help on using tickets. You may also have a look at Agilo extensions to the ticket.

1.3.13-PRO © 2008-2011 Agilo Software all rights reserved (this page was served in: 0.79447 sec.)

We're Hiring!