Did I find the right examples for you? yes no Crawl my project Python Jobs
All Samples(58) | Call(58) | Derive(0) | Import(0)
src/x/b/xbob.example.faceverify-1.0.0/xbob/example/faceverify/tests/__init__.py xbob.example.faceverify(Download)
# load PCA reference and check that it is still similar pca_ref = bob.machine.LinearMachine(bob.io.HDF5File(self.resource('pca_projector.hdf5'))) self.assertTrue(pca_ref.is_similar_to(pca))
src/x/b/xbob.spkrec-1.0.3/xbob/spkrec/tools/IVector.py xbob.spkrec(Download)
# create a Linear Machine # Runs whitening (first method) self.whitening_machine = bob.machine.LinearMachine(ivectors_matrix.shape[1],ivectors_matrix.shape[1]) # create the whitening trainer
def load_whitening_enroler(self, whitening_enroler_file): """Reads the whitening Enroler model from file""" # now, load the JFA base, if it is included in the file self.whitening_machine = bob.machine.LinearMachine(self.m_config.rt,self.m_config.rt)
if self.m_config.subspace_dimension_pca is not None: proj_hdf5file.cd('/pca') self.m_pca_machine = bob.machine.LinearMachine(proj_hdf5file) proj_hdf5file.cd('/plda') self.m_plda_base = bob.machine.PLDABase(proj_hdf5file)
def lda_load_projector(self, lda_projector_file): """Reads the UBM model from file""" # read LDA projector self.lda_machine = bob.machine.LinearMachine(bob.io.HDF5File(lda_projector_file)) # Allocates an array for the projected data
def wccn_load_projector(self, wccn_projector_file): """Reads the WCCN projector from file""" # read WCCN projector self.wccn_machine = bob.machine.LinearMachine(bob.io.HDF5File(wccn_projector_file)) # Allocates an array for the projected data
src/b/o/bob.spear-1.1.2/spear/tools/IVector.py bob.spear(Download)
# create a Linear Machine # Runs whitening (first method) self.whitening_machine = bob.machine.LinearMachine(ivectors_matrix.shape[1],ivectors_matrix.shape[1]) # create the whitening trainer
def load_whitening_enroler(self, whitening_enroler_file): """Reads the whitening Enroler model from file""" # now, load the JFA base, if it is included in the file self.whitening_machine = bob.machine.LinearMachine(self.m_config.rt,self.m_config.rt)
if self.m_config.subspace_dimension_pca is not None: proj_hdf5file.cd('/pca') self.m_pca_machine = bob.machine.LinearMachine(proj_hdf5file) proj_hdf5file.cd('/plda') self.m_plda_base = bob.machine.PLDABase(proj_hdf5file)
def lda_load_projector(self, lda_projector_file): """Reads the UBM model from file""" # read LDA projector self.lda_machine = bob.machine.LinearMachine(bob.io.HDF5File(lda_projector_file)) # Allocates an array for the projected data
def wccn_load_projector(self, wccn_projector_file): """Reads the WCCN projector from file""" # read WCCN projector self.wccn_machine = bob.machine.LinearMachine(bob.io.HDF5File(wccn_projector_file)) # Allocates an array for the projected data
src/x/b/xbob.thesis.elshafey2014-0.0.1a0/xbob/thesis/elshafey2014/tools/IVector.py xbob.thesis.elshafey2014(Download)
# create a Linear Machine # Runs whitening (first method) self.whitening_machine = bob.machine.LinearMachine(ivectors_matrix.shape[1],ivectors_matrix.shape[1]) # create the whitening trainer
def load_whitening_enroler(self, whitening_enroler_file): """Reads the whitening Enroler model from file""" # now, load the JFA base, if it is included in the file self.whitening_machine = bob.machine.LinearMachine(self.m_subspace_dimension_of_t, self.m_subspace_dimension_of_t)
def lda_load_projector(self, lda_projector_file): """Reads the UBM model from file""" # read LDA projector self.lda_machine = bob.machine.LinearMachine(bob.io.HDF5File(lda_projector_file)) # Allocates an array for the projected data
def wccn_load_projector(self, wccn_projector_file): """Reads the WCCN projector from file""" # read WCCN projector self.wccn_machine = bob.machine.LinearMachine(bob.io.HDF5File(wccn_projector_file)) # Allocates an array for the projected data
src/e/s/estimate.gender-0.4/estimate/gender/estimateGender.py estimate.gender(Download)
print ".. Loading PCA machine: %s.." %pca_file_name pca_file = bob.io.HDF5File(pca_file_name) pca_machine = bob.machine.LinearMachine(pca_file) del pca_file else:
if need_train: print ".. Applying PCA projection for training feature set.." train_F_pca = numpy.vstack([pca_machine(d) for d in train_F]) train_M_pca = numpy.vstack([pca_machine(d) for d in train_M]) print ".. Applying PCA projection for evaluation feature set.." eval_F_pca = numpy.vstack([pca_machine(d) for d in eval_F]) eval_M_pca = numpy.vstack([pca_machine(d) for d in eval_M])
src/f/a/facereclib-1.2.1/facereclib/tools/PLDA.py facereclib(Download)
if self.m_subspace_dimension_pca is not None: proj_hdf5file.cd('/pca') self.m_pca_machine = bob.machine.LinearMachine(proj_hdf5file) proj_hdf5file.cd('/plda') self.m_plda_base = bob.machine.PLDABase(proj_hdf5file)
src/f/a/facereclib-HEAD/facereclib/tools/PLDA.py facereclib(Download)
if self.m_subspace_dimension_pca is not None: proj_hdf5file.cd('/pca') self.m_pca_machine = bob.machine.LinearMachine(proj_hdf5file) proj_hdf5file.cd('/plda') self.m_plda_base = bob.machine.PLDABase(proj_hdf5file)
src/a/n/antispoofing.motion-1.1.1/antispoofing/motion/script/make_scores.py antispoofing.motion(Download)
except: try: machine = bob.machine.LinearMachine(macfile) except: print "Cannot load Linear or MLP machine from file %s" % args.machine
valid_index = ~numpy.isnan(input.sum(axis=1)) valid_data = input[valid_index,:] valid_output = machine(valid_data) output = numpy.ndarray((len(input), 1), dtype='float64') output[valid_index] = valid_output
src/f/a/facereclib-1.2.1/facereclib/tools/LDA.py facereclib(Download)
combined_matrix = numpy.dot(pca_machine.weights, self.m_machine.weights) # set new weight matrix (and new mean vector) of novel machine self.m_machine = bob.machine.LinearMachine(combined_matrix) self.m_machine.input_subtract = pca_machine.input_subtract
self.m_variances = f.read("Eigenvalues") f.cd("/Machine") self.m_machine = bob.machine.LinearMachine(f) # Allocates an array for the projected data self.m_projected_feature = numpy.ndarray(self.m_machine.shape[1], numpy.float64)
src/a/n/antispoofing.lbptop-1.0.4/antispoofing/lbptop/script/lbptop_make_scores.py antispoofing.lbptop(Download)
if(pcaFile != ''): hdf5File_pca = bob.io.HDF5File(pcaFile,openmode_string='r') pcaMachine = bob.machine.LinearMachine(hdf5File_pca) featureVector = pca.pcareduce(pcaMachine, featureVector);
if(machineType=='Linear'): hdf5File_linear = bob.io.HDF5File(machineFile,openmode_string='r') machine = bob.machine.LinearMachine(hdf5File_linear) scores = lda.get_scores(machine, featureVector) elif(machineType=='SVM'):
1 | 2 | 3 Next