Did I find the right examples for you? yes no Crawl my project Python Jobs
All Samples(511) | Call(511) | Derive(0) | Import(0)
src/x/b/xbob.example.faceverify-1.0.0/xbob/example/faceverify/tests/__init__.py xbob.example.faceverify(Download)
pca = train(images) if regenerate_references: pca.save(bob.io.HDF5File(self.resource('pca_projector.hdf5'), 'w')) # load PCA reference and check that it is still similar pca_ref = bob.machine.LinearMachine(bob.io.HDF5File(self.resource('pca_projector.hdf5')))
ubm = train(trainset, number_of_gaussians = 2) if regenerate_references: ubm.save(bob.io.HDF5File(self.resource('dct_ubm.hdf5'), 'w')) # load PCA reference and check that it is still similar ubm_ref = bob.machine.GMMMachine(bob.io.HDF5File(self.resource('dct_ubm.hdf5')))
model = enroll(enrollset, ubm, enroller) if regenerate_references: model.save(bob.io.HDF5File(self.resource('dct_model.hdf5'), 'w')) model_ref = bob.machine.GMMMachine(bob.io.HDF5File(self.resource('dct_model.hdf5')))
src/x/b/xbob.paper.example-0.2.0/xbob/paper/example/utils.py xbob.paper.example(Download)
def save_machine(X_mean, machine, filename): """Saves the machine and the mean vector into an hdf5 file""" f = bob.io.HDF5File(filename, 'w') f.set('X_mean', X_mean) machine.save(f) del f def load_machine(filename): """Loads the machine and the mean vector from an hdf5 file""" f = bob.io.HDF5File(filename)
src/a/n/antispoofing.lbptop-1.0.4/antispoofing/lbptop/script/lbptop_make_scores.py antispoofing.lbptop(Download)
#Loading the PCA machine if(pcaFile != ''): hdf5File_pca = bob.io.HDF5File(pcaFile,openmode_string='r') pcaMachine = bob.machine.LinearMachine(hdf5File_pca) featureVector = pca.pcareduce(pcaMachine, featureVector);
#Loading the machine if(machineType=='Linear'): hdf5File_linear = bob.io.HDF5File(machineFile,openmode_string='r') machine = bob.machine.LinearMachine(hdf5File_linear) scores = lda.get_scores(machine, featureVector)
src/a/n/antispoofing.lbptop-1.0.4/antispoofing/lbptop/script/lbptop_ldatrain.py antispoofing.lbptop(Download)
#### Saving the machines if(pca_reduction): hdf5File_pca = bob.io.HDF5File(os.path.join(outputDir, 'pca_machine_'+ str(energy) + '-' + models[i] +'.txt'),openmode_string='w') pcaMachine.save(hdf5File_pca) del hdf5File_pca hdf5File_lda = bob.io.HDF5File(os.path.join(outputDir, 'lda_machine_'+ str(energy) + "-" + models[i] +'.txt'),openmode_string='w')
src/a/n/antispoofing.dog-1.0.2/antispoofing/dog/script/make_scores.py antispoofing.dog(Download)
#Loading the PCA machine if(pcaFile != ''): hdf5File_pca = bob.io.HDF5File(pcaFile,openmode_string='r') pcaMachine = bob.machine.LinearMachine(hdf5File_pca) featureVector = pca.pcareduce(pcaMachine, featureVector);
#Loading the machine if(machineType=='Linear'): hdf5File_linear = bob.io.HDF5File(machineFile,openmode_string='r') machine = bob.machine.LinearMachine(hdf5File_linear) scores = lda.get_scores(machine, featureVector)
src/a/n/antispoofing.dog-1.0.2/antispoofing/dog/script/ldatrain.py antispoofing.dog(Download)
#### Saving the machines if(pca_reduction): hdf5File_pca = bob.io.HDF5File(os.path.join(outputDir, 'pca_machine_'+ str(energy) + '.txt'),openmode_string='w') pcaMachine.save(hdf5File_pca) del hdf5File_pca hdf5File_lda = bob.io.HDF5File(os.path.join(outputDir, 'lda_machine_'+ str(energy) +'.txt'),openmode_string='w')
src/a/n/antispoofing.competition_icb2013-1.1.0/antispoofing/competition_icb2013/script/ldatrain.py antispoofing.competition_icb2013(Download)
test_real = pca.pcareduce(pca_machine, test_real); test_attack = pca.pcareduce(pca_machine, test_attack) print "Saving PCA machine..." hdf5File_pca = bob.io.HDF5File(os.path.join(args.outputdir, 'pca_machine_'+ str(energy)), openmode_string='w') pca_machine.save(hdf5File_pca) del hdf5File_pca
lda_machine.shape = (lda_machine.shape[0], 1) #only use first component! print "Saving LDA machine..." hdf5File_lda = bob.io.HDF5File(os.path.join(args.outputdir, 'lda_machine_'+ str(energy)), openmode_string='w') lda_machine.save(hdf5File_lda) del hdf5File_lda
src/a/n/antispoofing.utils-1.1.3/antispoofing/utils/ml/svmCountermeasure.py antispoofing.utils(Download)
def writeNormalizationData(fileName,lowbound,highbound,mins,maxs): hdf5File = bob.io.HDF5File(fileName, openmode_string='w') hdf5File.append('lowbound',lowbound) hdf5File.append('highbound',highbound) hdf5File.append('mins',mins)
def readNormalizationData(fileName): #Opening HDF5 Files hdf5 = bob.io.HDF5File(fileName, openmode_string='r') lowbound = hdf5.read('lowbound')
src/a/n/antispoofing.lbptop-1.0.4/antispoofing/lbptop/spoof/scores.py antispoofing.lbptop(Download)
hdf5File = bob.io.HDF5File(outputFile, openmode_string='w') hdf5File.set('data',data) del hdf5File
src/a/n/antispoofing.lbptop-1.0.4/antispoofing/lbptop/script/lbptop_svmtrain.py antispoofing.lbptop(Download)
#Saving the machines if(pca_reduction): hdf5File_pca = bob.io.HDF5File(os.path.join(outputDir, 'pca_machine_'+ str(energy) + '-' + models[i] +'.txt'),openmode_string='w') pcaMachine.save(hdf5File_pca) del hdf5File_pca
1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 Next