pwem.viewers.viewer_coordinates module

class pwem.viewers.viewer_coordinates.CoordinateView(root, emSet: EMSet, protocol)[source]

Bases: View

show()[source]

This method should be overwritten to implement how this particular view will be displayed in desktop.

class pwem.viewers.viewer_coordinates.CoordinateViewer(tmpPath='./Tmp', **args)[source]

Bases: Viewer

class pwem.viewers.viewer_coordinates.MainWindow(root, setOfCoordinate, protocol)[source]

Bases: object

Coordinate viewer

addCoordinate(x, y, coordId=None)[source]

Create a coordinate

applyBandpassFilter()[source]

Apply the bandpass image filter

applyContrast()[source]
applyGaussianBlur()[source]

Apply the gaussian blur image filter

applyInvertContrast()[source]

Invert the image contrast

applyPowerHistogram()[source]

Create the histogram and the plot

calculateAveragePixel(shapeX, shapeY)[source]

Calculate the shape pixel average

canPick(event)[source]

Returns true if picking outside of any coordinate

clearImageGrid()[source]
drawCoordinates(micId)[source]

Draw the coordinates over the micrograph

eraserActivate()[source]

Recovering some actions when eraser button is pressed

extractImages()[source]

Show the particles

extractRegion(x, y)[source]

Take the particle region

filamentActivate()[source]

Recovering some actions when filament button is pressed

filterCoordinates(value)[source]

Handle the range of pixel values that will be removed

getPixelValue(x, y)[source]

Return the pixel value in the given x and y coordinates

histWindowClose()[source]
histWindowSaveClose()[source]

Save the new coordinates taking into account the sliders selected pixel range

isMoveIn(x, y)[source]
loadCoordinates(micrograph)[source]

Load the coordinate for a given micrograph

moveParticle(index)[source]
nearCoordinates(index)[source]

Calculate the near coordinates to a given coordinate

onBoxSizeSlider(event)[source]

Handle box size slider motion

onClickPress(event)[source]

Actions when the mouse left-click is pressed

onClickRelease(event)[source]

Actions when the mouse left-click is released

onDrag(event)[source]

Move the image and shapes on drag

onDragActivate()[source]

Allow drag to move

onFitActivate()[source]

Fit to display area and reset all parameters

onMotion(event)[source]

Handle the eraser, picking filament and drag actions

onParticlesWindowClosing()[source]

Close the particles window

onSliderMapMove(value)[source]
onSliderRelease(event)[source]

Handle box size slider release

onTableClick(event)[source]

Handle the event when a row in the table is clicked to select a micrograph

onZoomActivate()[source]

Allow zoom on scroll

onZoomImage(direction, event)[source]

Zoom action

openFile()[source]

Open a file dialog to load an image

pickingActivate()[source]

Recovering some actions when picking button is pressed

plotHistogram(ejes)[source]

Plot the micrograph histogram

recoveryPointer(event)[source]

Restoring the default cursor

removeCoordinates(value1, value2)[source]

Remove the coordinate taking into account the pixel values

resetMicrograph()[source]

Remove all coordinates from current micrograph

resizeRadious()[source]

Calculate the shape radius taking into account the box size value

restoreMicrograph()[source]

Restore all removed coordinates from current micrograph

selectCoordinate(event)[source]
showCircles()[source]

Draw a circle on the particle

showCoordinates()[source]

Load and display the selected micrograph and coordinates

showPalette()[source]

Color picker dialog

showParticles(geometry=None)[source]

Create the particles window

showPoint()[source]

Draw a point on the particle

showSquare()[source]

Draw a square on the particle

updateImage(event)[source]

Update the image with new size

updateParticle(index)[source]
updateSize(event=None)[source]

Update the size value label when the slider is moved

zoomerM(event)[source]

Decrease size

zoomerP(event)[source]

Increase size