Example #1
0
 def list_options(self, tp):
     if tp == 'any':
         raise RuntimeError("Can't expand the 'any' type")
     elif tp == 'base':
         return list(fk.base_kernel_families())
     else:
         raise RuntimeError('Unknown type: %s' % tp)
Example #2
0
 def list_options(self, tp):
     if tp == 'any':
         raise RuntimeError("Can't expand the 'any' type")
     elif tp == 'base':
         return list(fk.base_kernel_families())
     else:
         raise RuntimeError('Unknown type: %s' % tp)
Example #3
0
 def list_options(self, tp):
     if tp in ['1d', 'multi']:
         raise RuntimeError("Can't expand the '%s' type" % tp)
     elif tp == 'base':
         return [fam.default() for fam in fk.base_kernel_families(self.base_kernels)]
     elif tp == 'mask':
         return list(fk.base_kernels(self.ndim, self.base_kernels))
     else:
         raise RuntimeError('Unknown type: %s' % tp)
Example #4
0
 def list_options(self, tp):
     if tp in ['1d', 'multi']:
         raise RuntimeError("Can't expand the '%s' type" % tp)
     elif tp == 'base':
         return [
             fam.default()
             for fam in fk.base_kernel_families(self.base_kernels)
         ]
     elif tp == 'mask':
         return list(fk.base_kernels(self.ndim, self.base_kernels))
     else:
         raise RuntimeError('Unknown type: %s' % tp)
def make_kernel_description_table():
    '''A helper to generate a latex table listing all the kernels used, and their descriptions.'''
    entries = [];
    rownames = [];
    
    colnames = ['', 'Description', 'Parameters' ]
    for k in fk.base_kernel_families():
        # print "dataset: %s kernel: %s\n" % (rt[0], rt[-1].pretty_print())
        rownames.append( k.latex_print() )
        entries.append([ k.family().description(), k.family().params_description()])
    
    utils.latex.table('../latex/tables/kernel_descriptions.tex', rownames, colnames, entries, 'kernel_descriptions')
Example #6
0
def make_kernel_description_table():
    '''A helper to generate a latex table listing all the kernels used, and their descriptions.'''
    entries = []
    rownames = []

    colnames = ['', 'Description', 'Parameters']
    for k in fk.base_kernel_families():
        # print "dataset: %s kernel: %s\n" % (rt[0], rt[-1].pretty_print())
        rownames.append(k.latex_print())
        entries.append(
            [k.family().description(),
             k.family().params_description()])

    utils.latex.table('../latex/tables/kernel_descriptions.tex', rownames,
                      colnames, entries, 'kernel_descriptions')