fix wartings for 32bit build

This commit is contained in:
marina.kolpakova 2013-01-10 16:30:18 +04:00
parent c0462358ca
commit e903ce10ce
2 changed files with 23 additions and 4 deletions

View File

@ -76,6 +76,15 @@ void sft::write(cv::FileStorage& fs, const string&, const ICF& f)
sft::ICFFeaturePool::~ICFFeaturePool(){}
// #define USE_LONG_SEEDS
#if defined USE_LONG_SEEDS
# define FEATURE_RECT_SEED 8854342234LU
#else
# define FEATURE_RECT_SEED 88543422LU
#endif
# define DCHANNELS_SEED 314152314LU
#undef USE_LONG_SEEDS
void sft::ICFFeaturePool::fill(int desired)
{
int mw = model.width;
@ -88,8 +97,8 @@ void sft::ICFFeaturePool::fill(int desired)
pool.reserve(nfeatures);
sft::Random::engine eng(8854342234LU);
sft::Random::engine eng_ch(314152314LU);
sft::Random::engine eng(FEATURE_RECT_SEED);
sft::Random::engine eng_ch(DCHANNELS_SEED);
sft::Random::uniform chRand(0, N_CHANNELS - 1);

View File

@ -239,11 +239,21 @@ void cv::Octave::processPositives(const Dataset* dataset, const FeaturePool* poo
nnegatives = cvRound(nnegatives * total / (double)npositives);
}
// #define USE_LONG_SEEDS
#if defined USE_LONG_SEEDS
# define INDEX_ENGINE_SEED 764224349868LU
#else
# define INDEX_ENGINE_SEED 76422434LU
#endif
# define DX_DY_SEED 65633343LU
#undef USE_LONG_SEEDS
void cv::Octave::generateNegatives(const Dataset* dataset, const FeaturePool* pool)
{
// ToDo: set seed, use offsets
sft::Random::engine eng(65633343LU);
sft::Random::engine idxEng(764224349868LU);
sft::Random::engine eng(DX_DY_SEED);
sft::Random::engine idxEng(INDEX_ENGINE_SEED);
int h = boundingBox.height;