Did I find the right examples for you? yes no

All Samples(15)  |  Call(15)  |  Derive(0)  |  Import(0)

src/u/c/UCSBsketch-HEAD/linux/Utils/ForegroundFilter.py   UCSBsketch(Download)
    def filterForeground(self, newImage):
        diffImage = cv.CloneMat(self._bgImage)
        retImage = cv.CloneMat(newImage)
        cv.AbsDiff(newImage, self._bgImage, diffImage)
        cv.AddWeighted(retImage, 1.0, diffImage, 0.5, 0.0, retImage)
    retImage = cv.CloneMat(bgImage)
    diffImage = cv.CloneMat(bgImage)
    cv.AbsDiff(bgImage, newImage, diffImage)
    diffImage = max_allChannel(diffImage)
 
    # and correspond to thin, ink-like differences
    inkDifferences = cv.CloneMat(diffImage)
    cv.AbsDiff(diffImage, diffImageEroded, inkDifferences)
    cv.Smooth(inkDifferences, inkDifferences, smoothtype=cv.CV_MEDIAN)
    cv.Dilate(inkDifferences, inkDifferences, iterations=4)
    largeBlobMask = cv.CreateMat(diffImage.rows,
                                 diffImage.cols, diffImage.type)
    cv.AbsDiff(smoothDiff, diffImageEroded, largeBlobMask)
    cv.Max(largeBlobMask, smoothDiff, largeBlobMask)
    cv.Threshold(largeBlobMask, largeBlobMask, largeBlobThresh, 255, cv.CV_THRESH_BINARY)

src/c/i/cinemetrics-HEAD/02_1_shot-detection.py   cinemetrics(Download)
		# METHOD #1: find the number of pixels that have (significantly) changed since the last frame
		diff = cv.CreateImage(cv.GetSize(img), cv.IPL_DEPTH_8U, 3)
		cv.AbsDiff(img_hsv, prev_img, diff)
		cv.Threshold(diff, diff, 10, 255, cv.CV_THRESH_BINARY)
		d_color = 0

src/m/o/movement-HEAD/Movement.py   movement(Download)
    # Difference between frames
    cv.Smooth(capture, current, cv.CV_BLUR, 15,15)
    cv.AbsDiff(current, previous, difference)
 
    frame = cv.CreateImage(frame_size, 8, 1)

src/u/c/UCSBsketch-HEAD/linux/Utils/BoardChangeWatcher.py   UCSBsketch(Download)
        # Track the new strokes that are added
        captureDiffMask = cv.CloneMat(self._fgFilter.getBackgroundImage())
        cv.AbsDiff(captureDiffMask, self._lastCaptureImage, captureDiffMask)
        captureDiffMask = max_allChannel(captureDiffMask)
        cv.Threshold(captureDiffMask, captureDiffMask,
                thisDiff = cv.CreateMat(prev.rows, prev.cols, prev.type)
            else:
                cv.AbsDiff(prev, frame, thisDiff)
                cv.Max(thisDiff, cumulativeDiff, cumulativeDiff)
        # Now that we have the max sequential difference between frames,

src/m/o/motion_tracking-HEAD/track.py   motion_tracking(Download)
 
			# Subtract the current frame from the moving average.
			cv.AbsDiff( color_image, running_average_in_display_color_depth, difference )
 
			# Convert the image to greyscale.

src/c/i/cinemetrics-HEAD/04_1_motion.py   cinemetrics(Download)
 
			diff = cv.CreateImage(cv.GetSize(img), cv.IPL_DEPTH_8U, 3)
			cv.AbsDiff(img, prev_img, diff)
			cv.Threshold(diff, diff, 10, 255, cv.CV_THRESH_BINARY)
			d_color = 0

src/l/a/lazy-HEAD/lazy.py   lazy(Download)
    def get_diff(self, img1, img2):
        diff = cv.CreateImage(cv.GetSize(img1), img1.depth, 1)
        diff = cv.CloneImage(img1)
        cv.AbsDiff(img1, img2, diff)
        return diff

src/h/t/HTM-Camera-Toolkit-HEAD/src/CameraFrame.py   HTM-Camera-Toolkit(Download)
    #find motion image, then find feature corners from that
    if self._prevIplImage:
      cv.AbsDiff(self._inputImage, self._prevIplImage, self._diffImage)
    else:
      cv.Copy(self._inputImage, self._diffImage)

src/h/t/HTM-Camera-Toolkit-HEAD/src/NetworkFrame.py   HTM-Camera-Toolkit(Download)
    #find motion image, then find feature corners from that
    if self._prevIplImage:
      cv.AbsDiff(self._inputImage, self._prevIplImage, self._diffImage)
    else:
      cv.Copy(self._inputImage, self._diffImage)

src/c/a/card_scan-HEAD/detect_card.py   card_scan(Download)
def detect_card(grey_image, grey_base, thresh=100):
	diff = cv.CloneImage(grey_image)
	cv.AbsDiff(grey_image, grey_base, diff)
 
	edges = cv.CloneImage(grey_image)

  1 | 2  Next