原创 Leetcode題解55- Jump Game

題目:Given an array of non-negative integers, you are initially positioned at the first index of the array.Each element i

原创 Leetcode題解70-Climbing Stairs

題目:You are climbing a stair case. It takes n steps to reach to the top.Each time you can either climb 1 or 2 steps. In

原创 Leetcode題解42-Trapping Rain Water

題目:Given n non-negative integers representing an elevation map where the width of each bar is 1, compute how much water

原创 leetcode題解35- Search Insert Position

題目:Given a sorted array and a target value, return the index if the target is found. If not, return the index where it

原创 leecode題解22- Generate Parentheses

題目:Given n pairs of parentheses, write a function to generate all combinations of well-formed parentheses.For example,

原创 leetcode題解34- Search for a Range

題目:Given an array of integers nums sorted in ascending order, find the starting and ending position of a given target v

原创 leetcode題解32- Longest Valid Parentheses

題目:Given a string containing just the characters '(' and ')', find the length of the longest valid (well-formed) parent

原创 RANSAC隨機採樣一致算法

RANSAC簡介 RANSAC(RAndom SAmple Consensus,隨機採樣一致)算法是從一組含有“外點”(outliers)的數據中正確估計數學模型參數的迭代算法。“外點”一般指的的數據中的噪聲,比如說匹配中的誤匹配和估計曲

原创 圖像Non-local means 去噪算法matlab實現

function [output]=NLmeansfilter(input,t,f,h) %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% % %

原创 李航《統計學習方法》第二章-感知機的python實現

重點:感知機是一種二類分類的線性分類模型,屬於判別模型。感知機對應於特徵空間中的分離超平面 w*x+b=0損失函數:誤分類點到分離超平面的總距離。學習算法:隨機梯度下降法。有原始和對偶兩種形式。當訓練數據線性可分時,感知機學習算法存在無窮

原创 KD-Tree的C++源碼實現

#include<cstdio> #include<algorithm> #include<vector> using namespace std; class Node{ public: int location; int

原创 雙目立體視覺的SSD立體匹配matlab代碼

# Licensed under the MIT License import numpy as np from PIL import Image def stereo_match(left_img, right_img, kerne

原创 堆排序的Python代碼

# -*- coding: utf-8 -*- """ Created on Fri Jul 5 10:13:16 2019 @author: Yuki """ def heapAdjust(nums, Len, index):

原创 雙目立體匹配SAD的matlab源碼分析

clear all clc left=double(rgb2gray(imread('left.png'))); right=double(rgb2gray(imread('right.png'))); [m n]=size(left