:param ul: microliters as a float
        :param func: must be one of 'aspirate' or 'dispense'
        :return: microliters/mm as a float
14380
def _ul_per_mm(self, ul: float, func: str) -> float:
        
        sequence = self.ul_per_mm[func]
        return pipette_config.piecewise_volume_conversion(ul, sequence)
1160323
def ts_func(f):
    
    def wrap_func(df, *args):
        # TODO: should vectorize to apply over all columns?
        return Chromatogram(f(df.values, *args), df.index, df.columns)
    return wrap_func
86935
def timing(func):
    """"""
    @functools.wraps(func)
    def wrap(*args, **kw):
        t0 = time()
        result = func(*args, **kw)
        t1 = time()
        print('func:%r args:[%r, %r] took: %2.4f sec' %
              (func.__name__, args, kw, t1 - t0))
        return result
    return wrap
1027963
def _func(self, volume, params):
        
        e0, b0, b1, v0 = tuple(params)
        eta = (volume / v0) ** (1. / 3.)
        squiggle = -3.*np.log(eta)
        return e0 + b0 * v0 * squiggle ** 2 / 6. * (3. + squiggle * (b1 - 2))
317655
def _vasprun_float(f):
    
    try:
        return float(f)
    except ValueError as e:
        f = f.strip()
        if f == '*' * len(f):
            warnings.warn('Float overflow (*******) encountered in vasprun')
            return np.nan
        raise e
279433
def _aspirate_plunger_position(self, ul):
        
        millimeters = ul / self._ul_per_mm(ul, 'aspirate')
        destination_mm = self._get_plunger_position('bottom') + millimeters
        return round(destination_mm, 6)
1212636
public static FloatBinding ulp(final ObservableFloatValue f) {
        return createFloatBinding(() -> Math.ulp(f.get()), f);
    }
755264
def _my_partial(func, *args, **kwargs):
    
    newobj = partial(func, *args, **kwargs)
    # monkey patch
    newobj.from_string = FloatWithUnit.from_string
    return newobj
1222827
def accumulate_impl(func, sequence):
    # pylint: disable=no-name-in-module
    
    if six.PY3:
        from itertools import accumulate
        return accumulate(sequence, func)
    else:
        return _accumulate(sequence, func)
51537
def _make_ufunc(func, index=Ellipsis, **kwargs):  # noqa: D202
    """"""

    def _ufunc(ary):
        target = np.empty(ary.shape[:-2])
        for idx in np.ndindex(target.shape):
            target[idx] = np.asarray(func(ary[idx].ravel(), **kwargs))[index]
        return target

    return _ufunc
340917
def get_indentation(func):
    
    src_lines = getsourcelines(func)[0]
    for line in src_lines:
        if not (line.startswith('@') or line.startswith('def') or line.lstrip().startswith('#')):
            return line[:len(line) - len(line.lstrip())]
    return pytypes.default_indent
111526
def _wrap(cls, func):
        

        if isinstance(func, cls):
            return func
        return functools.update_wrapper(cls(func), func)
396856
def _compose_func(func, args_func=lambda req_info: [req_info.index]):
    
    return FuncInfo(func=func, args_func=args_func)
244339
def call_cur(f):
  ""
  @functools.wraps(f)
  def f2(self, *args, **kwargs):
    with self.withcur() as cur:
      return f(self, cur, *args, **kwargs)
  return f2
1226512
public static boolean gradient( FunctionNtoS func , FunctionNtoN gradient ,
									double param[] , double tol )
	{
		return gradient(func, gradient, param, tol, Math.sqrt(UtilEjml.EPS));
	}
350619
def unicode_compact(func):
    

    @wraps(func)
    def wrapped(self, text, *a, **kw):
        if not isinstance(text, six.text_type):
            text = text.decode('utf-8')
        return func(self, text, *a, **kw)

    return wrapped
1346547
def wrap(self, func):
        
        @six.wraps(func)
        def wrapper(*args, **kwargs):
            try:
                return self.aggregate()
            except KeyError:
                return func(*args, **kwargs)
        return wrapper