Up | ScorpionEx.py | SetValue | GetValue | SetConfigValue | GetConfigValue | GetImageMatr | DecimateMatr | RegisterCallback | RegisterPlugin | RegisterUserManager | PluginChanged | ExecuteCmd | Other

 

  

 
DecimateMatr

DecimateMatr(matr,pitch,size=None,center=(0,0)) - returns the decimated matrix

Parameters:

  • matr - arr matrix, typically retrieved by GetImageMatr function

  • pitch - a scalar or tuple (px,py) for either aniso decimation or not. Using integers as pitch increases decimation speed (0..n)

  • size - tuple (dx,dy) - ROI in matr to decimate, if omitted or None decimates whole matr

  • center - tuple (x,y) - center offset if size<matr.dim(), defaults to matr center if omitted or None

Note: ROI is clipped if outside image, causing smaller output size

Example 1: Decimate image

# used to provide access to image from python
img=GetImageMatr('Image') #get the image
dec=DecimateMatr(img,2)
SetImageMatr('Decimated',dec)
 

Scorpion Vision Version XV  : Build 764 - Date: 20200529
Scorpion Vision Software® is a registered trademark of Tordivel AS.
Copyright © 2000 - 2020 Tordivel AS.