source:
proiecte/pmake3d/make3d_original/Make3dSingleImageStanford_version0.1/third_party/BlueCCal/MultiCamSelfCal/Ransac/nsamples.m
Last change on this file was 37, checked in by , 14 years ago | |
---|---|
File size: 296 bytes |
Line | |
---|---|
1 | %SampleCnt calculates number of samples needed to be done |
2 | |
3 | function SampleCnt = nsamples(ni, ptNum, pf, conf) |
4 | q = prod ([(ni-pf+1) : ni] ./ [(ptNum-pf+1) : ptNum]); |
5 | |
6 | if (1 -q) < eps |
7 | SampleCnt = 1; |
8 | else |
9 | SampleCnt = log(1 - conf) / log(1 - q); |
10 | end |
11 | |
12 | if SampleCnt < 1 |
13 | SampleCnt = 1; |
14 | end |
Note: See TracBrowser
for help on using the repository browser.