boxSum

sans.guiframe.local_perspectives.plotting.boxSum

class sans.guiframe.local_perspectives.plotting.boxSum.BoxSum(base, axes, color='black', zorder=3, x_min=0.0080000000000000002, x_max=0.0080000000000000002, y_min=0.0025000000000000001, y_max=0.0025000000000000001)

Bases: sans.guiframe.local_perspectives.plotting.BaseInteractor._BaseInteractor

Boxsum Class: determine 2 rectangular area to compute the sum of pixel of a Data. Uses PointerInteractor , VerticalDoubleLine,HorizontalDoubleLine. @param zorder: Artists with lower zorder values are drawn first. @param x_min: the minimum value of the x coordinate @param x_max: the maximum value of the x coordinate @param y_min: the minimum value of the y coordinate @param y_max: the maximum value of the y coordinate

clear()

Clear the slicer and all connected events related to this slicer

clear_markers()

Clear old markers and interfaces.

connect_markers(markers)

Connect markers to callbacks

dpixel(x, y, nudge=False)

Return the step size in data coordinates for a small step in screen coordinates. If nudge is False (default) the step size is one pixel. If nudge is True, the step size is 0.2 pixels.

draw()
freeze_axes()
get_params()

Store a copy of values of parameters of the slicer into a dictionary. :return params: the dictionary created

get_result()

return the result of box summation

move(x, y, ev)

Process move to a new position, making sure that the move is allowed.

moveend(ev)

After a dragging motion this function is called to compute the error and the sum of pixel of a given data 2D

onClick(ev)

Prepare to move the artist. Calls save() to preserve the state for later restore().

onDrag(ev)

Move the artist. Calls move() to update the state, or restore() if the mouse leaves the window.

onHilite(ev)

Hilite the artist reporting the event, indicating that it is ready to receive a click.

onKey(ev)

Respond to keyboard events. Arrow keys move the widget. Escape restores it to the position before the last click.

Calls move() to update the state. Calls restore() on escape.

onLeave(ev)

Restore the artist to the original colour when the cursor leaves.

onRelease(ev)
restore()

Restore the roughness for this layer.

save(ev)

Remember the roughness for this layer and the next so that we can restore on Esc.

set_cursor(x, y)
set_layer(n)

Allow adding plot to the same panel :param n: the number of layer

set_panel_name(name)

Store the name of the panel associated to this slicer @param name: the name of this panel

set_params(params)

Receive a dictionary and reset the slicer with values contained in the values of the dictionary. :param params: a dictionary containing name of slicer parameters and

values the user assigned to the slicer.
thaw_axes()
update()

Respond to changes in the model by recalculating the profiles and resetting the widgets.

class sans.guiframe.local_perspectives.plotting.boxSum.HorizontalDoubleLine(base, axes, color='black', zorder=5, x=0.5, y=0.5, center_x=0.0, center_y=0.0)

Bases: sans.guiframe.local_perspectives.plotting.BaseInteractor._BaseInteractor

Select an annulus through a 2D plot

clear()

Clear this figure and its markers

clear_markers()

Clear old markers and interfaces.

connect_markers(markers)

Connect markers to callbacks

dpixel(x, y, nudge=False)

Return the step size in data coordinates for a small step in screen coordinates. If nudge is False (default) the step size is one pixel. If nudge is True, the step size is 0.2 pixels.

get_params()

Store a copy of values of parameters of the slicer into a dictionary. :return params: the dictionary created

move(x, y, ev)

Process move to a new position, making sure that the move is allowed.

moveend(ev)

After a dragging motion reset the flag self.has_move to False

onClick(ev)

Prepare to move the artist. Calls save() to preserve the state for later restore().

onDrag(ev)

Move the artist. Calls move() to update the state, or restore() if the mouse leaves the window.

onHilite(ev)

Hilite the artist reporting the event, indicating that it is ready to receive a click.

onKey(ev)

Respond to keyboard events. Arrow keys move the widget. Escape restores it to the position before the last click.

Calls move() to update the state. Calls restore() on escape.

onLeave(ev)

Restore the artist to the original colour when the cursor leaves.

onRelease(ev)
restore()

Restore the roughness for this layer.

save(ev)

Remember the roughness for this layer and the next so that we can restore on Esc.

set_cursor(x, y)

Update the figure given x and y

set_layer(n)

Allow adding plot to the same panel @param n: the number of layer

set_params(params)

Receive a dictionary and reset the slicer with values contained in the values of the dictionary. :param params: a dictionary containing name of slicer parameters and

values the user assigned to the slicer.
update(x1=None, x2=None, y1=None, y2=None, width=None, height=None, center=None)

Draw the new roughness on the graph. :param x1: new maximum value of x coordinates :param x2: new minimum value of x coordinates :param y1: new maximum value of y coordinates :param y2: new minimum value of y coordinates :param width: is the width of the new rectangle :param height: is the height of the new rectangle :param center: provided x, y coordinates of the center point

class sans.guiframe.local_perspectives.plotting.boxSum.PointInteractor(base, axes, color='black', zorder=5, center_x=0.0, center_y=0.0)

Bases: sans.guiframe.local_perspectives.plotting.BaseInteractor._BaseInteractor

Draw a point that can be dragged with the marker. this class controls the motion the center of the BoxSum

clear()

Clear this figure and its markers

clear_markers()

Clear old markers and interfaces.

connect_markers(markers)

Connect markers to callbacks

dpixel(x, y, nudge=False)

Return the step size in data coordinates for a small step in screen coordinates. If nudge is False (default) the step size is one pixel. If nudge is True, the step size is 0.2 pixels.

get_params()
move(x, y, ev)

Process move to a new position, making sure that the move is allowed.

moveend(ev)
onClick(ev)

Prepare to move the artist. Calls save() to preserve the state for later restore().

onDrag(ev)

Move the artist. Calls move() to update the state, or restore() if the mouse leaves the window.

onHilite(ev)

Hilite the artist reporting the event, indicating that it is ready to receive a click.

onKey(ev)

Respond to keyboard events. Arrow keys move the widget. Escape restores it to the position before the last click.

Calls move() to update the state. Calls restore() on escape.

onLeave(ev)

Restore the artist to the original colour when the cursor leaves.

onRelease(ev)
restore()

Restore the roughness for this layer.

save(ev)

Remember the roughness for this layer and the next so that we can restore on Esc.

set_cursor(x, y)
set_layer(n)

Allow adding plot to the same panel @param n: the number of layer

set_params(params)
update(center_x=None, center_y=None)

Draw the new roughness on the graph.

class sans.guiframe.local_perspectives.plotting.boxSum.VerticalDoubleLine(base, axes, color='black', zorder=5, x=0.5, y=0.5, center_x=0.0, center_y=0.0)

Bases: sans.guiframe.local_perspectives.plotting.BaseInteractor._BaseInteractor

Draw 2 vertical lines moving in opposite direction and centered on a point (PointInteractor)

clear()

Clear this slicer and its markers

clear_markers()

Clear old markers and interfaces.

connect_markers(markers)

Connect markers to callbacks

dpixel(x, y, nudge=False)

Return the step size in data coordinates for a small step in screen coordinates. If nudge is False (default) the step size is one pixel. If nudge is True, the step size is 0.2 pixels.

get_params()

Store a copy of values of parameters of the slicer into a dictionary. @return params: the dictionary created

move(x, y, ev)

Process move to a new position, making sure that the move is allowed.

moveend(ev)

After a dragging motion reset the flag self.has_move to False

onClick(ev)

Prepare to move the artist. Calls save() to preserve the state for later restore().

onDrag(ev)

Move the artist. Calls move() to update the state, or restore() if the mouse leaves the window.

onHilite(ev)

Hilite the artist reporting the event, indicating that it is ready to receive a click.

onKey(ev)

Respond to keyboard events. Arrow keys move the widget. Escape restores it to the position before the last click.

Calls move() to update the state. Calls restore() on escape.

onLeave(ev)

Restore the artist to the original colour when the cursor leaves.

onRelease(ev)
restore()

Restore the roughness for this layer.

save(ev)

Remember the roughness for this layer and the next so that we can restore on Esc.

set_cursor(x, y)

Update the figure given x and y

set_layer(n)

Allow adding plot to the same panel :param n: the number of layer

set_params(params)

Receive a dictionary and reset the slicer with values contained in the values of the dictionary. @param params: a dictionary containing name of slicer parameters and values the user assigned to the slicer.

update(x1=None, x2=None, y1=None, y2=None, width=None, height=None, center=None)

Draw the new roughness on the graph. :param x1: new maximum value of x coordinates :param x2: new minimum value of x coordinates :param y1: new maximum value of y coordinates :param y2: new minimum value of y coordinates :param width: is the width of the new rectangle :param height: is the height of the new rectangle :param center: provided x, y coordinates of the center point

Table Of Contents

Previous topic

boxSlicer

Next topic

detector_dialog

This Page