- 博客(12)
- 资源 (2)
- 收藏
- 关注
原创 hough_voting_gpu
hough_voting_gpu_op.cc/* Copyright 2015 Google Inc. All Rights Reserved.Licensed under the Apache License, Version 2.0 (the "License");you may not use this file except in compliance with the Licens...
2018-07-05 10:50:38
699
1
原创 Kmeans++算法C++代码
#include#include#include#include#include#includeusing namespace std;struct Result_Sort{ int minlocation; double result;};//排序,对所有点分簇,返回分簇的簇,和距离的大小Result_Sort Sort(vector tmp, R
2017-09-21 10:11:12
1993
原创 Python做字符串处理
今天在修改C++和Matlab的代码的时候,出现了以下问题。C++调用Eigen,创建的矩阵,下标是从0开始,Matlab的则是从1开始。下面为Matlab代码,需要转换成C++,即将所有的下标索引值减1. A1 6 * M(10) - 6 * M(14) - 6 * M(18) + 6 * M(2) + 6 * M(28) - 6 * M(32) - 6 * M(36) - 6 * M(
2017-09-16 21:43:23
319
原创 Python抓取网页图片
#coding=utf-8import urllibimport redef getHtml(url): page = urllib.urlopen(url) html = page.read() return htmldef getImg(html): reg = r'src="(.+?\.jpg)" pic_ext'
2016-03-01 16:19:33
488
原创 基于ICM的图像切割 MATLAB
Matlab程序代码 function [seg]=MRMRF(w,class_number,potential,maxIter)%MRMRF图像分割算法%w-待分解图像的多尺度序列%class_number-分类数%potential-potts模型势函数%maxIter-最大迭代次数%多分辨率表达的尺度数L=size(w,1);%分割结果的多尺度序列
2016-03-01 16:16:54
3184
1
原创 置信度传播算法
% % MP algorithm% Qi,j(x)=1./(1+exp(-2*x*y/sigma^2)) for each i,j such that hi,j=1.% in code 0->-1,1->+1,such as q0 means q-1;p0 means P(X=-1|Y=y);% BPSK 0----->+1,1----->-1;function [out,success,iter
2015-12-12 21:38:30
2314
原创 C语言实现动态数组大小
C语言动态数组大小C语言中的数组大小是固定的,定义的时候必须要给一个常量值,不能是变量。这带来了很大的不便,如果数组过小,不能容下所有数组,如果过大,浪费资源。//C语言动态分配数组大小#include#includeint main(){ //从控制台获取数组大小 int N; int *a; int i; printf("Input array length");
2015-11-15 13:33:44
4058
1
原创 基于模板匹配的数字识别
基于模板匹配的数字识别,将标准的8*16像素的数字0123456789读取,二值化,对每个数字进行等分区域分割,统计每个区域内的黑色像素点的个数,即为特征初值。采用欧式距离的模板匹配法。z//基于模板匹配的数字识别#include#include#include#include #includeusing namespace std; int main()
2015-11-14 12:14:17
7124
原创 小波变换图像处理
应用小波变换对图像处理图像金字塔,每一层的像素数为(2^i,2^j):图像金字塔基本操作 对一张图像不断的模糊之后向下采样,得到不同分辨率的图像,同时每次得到的 新的图像宽与高是原来图像的1/2,http://baike.baidu.com/link?url=uxUdGHjdQPia38hy6sElpAwpjkiyX0tUx0DH-I6JC2LrEWIG9ov8WKibm29zz60fiAE3
2015-11-13 12:35:00
6695
原创 HOUGH变换检测圆
本文的算法是实现HOUGH变换对圆的检测 #include #include #include #include using namespace std; //搜索最大概率圆int selectmax(int count_1[],int a0,int b0,int r0){ int time,max,temp; time=a0*b0*r0; max=count
2015-11-13 12:27:08
693
原创 二值连通区域检测
clear all;close all;clc;img=imread('guangshan1.jpg');img_r=img(:,:,1);imgn=img_r>128;s=uint8(1-imgn);imshow(mat2gray(s));[m n]=size(s);tmp=zeros(m,n); %标记图像label=1;queue_head
2015-10-27 15:53:47
1029
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人
RSS订阅