Transform function for adding paths
500622
function projectConfigAddPaths(config) {
	config.paths.src[TASK_NAME]  = config.dirs.src  + '/images/';
	config.paths.dest[TASK_NAME] = config.dirs.dest + '/images/';

	return config;
}
33875
def append_paths(sprocket, paths) # :nodoc:
      paths or return
      paths.each do |path|
        append_path sprocket, path
      end
    end
1210478
def _ExpandPath(self, target, vals, paths):
    """"""
    if target not in self._TARGETS:
      return
    expanded = []
    for val in vals:
      # Null entries specify the current directory, so :a::b:c: is equivalent
      # to .:a:.:b:c:.
      shellvar = self._SHELLVAR_RE.match(val)
      if not val:
        expanded.append(".")
      elif shellvar:
        # The value may actually be in braces as well. Always convert to upper
        # case so we deal with stuff like lowercase csh path.
        existing = paths.get(shellvar.group(1).upper())
        if existing:
          expanded.extend(existing)
        else:
          expanded.append(val)
      else:
        expanded.append(val)
    paths[target] = expanded
972357
function replacePath (path, keys) {
  var index = 0;

  function replace (_, escaped, prefix, key, capture, group, suffix, escape) {
    if (escaped) {
      return escaped;
    }

    if (escape) {
      return '\\' + escape;
    }

    var repeat   = suffix === '+' || suffix === '*';
    var optional = suffix === '?' || suffix === '*';

    keys.push({
      name:      key || index++,
      delimiter: prefix || '/',
      optional:  optional,
      repeat:    repeat
    });

    prefix = prefix ? ('\\' + prefix) : '';
    capture = escapeGroup(capture || group || '[^' + (prefix || '\\/') + ']+?');

    if (repeat) {
      capture = capture + '(?:' + prefix + capture + ')*';
    }

    if (optional) {
      return '(?:' + prefix + '(' + capture + '))?';
    }

    // Basic parameter support.
    return prefix + '(' + capture + ')';
  }

  return path.replace(PATH_REGEXP, replace);
}
671623
def _process_transform(self, data, transform, step_size):
    '''
    
    '''
    if isinstance(transform, (list,tuple,set)):
      return { t : self._transform(data,t,step_size) for t in transform }
    elif isinstance(transform, dict):
      return { tn : self._transform(data,tf,step_size) for tn,tf in transform.items() }
    return self._transform(data,transform,step_size)
557333
private Path2D getPath(double simplifyTolerance, BoundingBox boundingBox,
			ProjectionTransform transform, LineString lineString) {

		Path2D path = null;

		// Try to simplify the number of points in the LineString
		List<Point> lineStringPoints = simplifyPoints(simplifyTolerance,
				lineString.getPoints());

		for (Point point : lineStringPoints) {

			Point projectedPoint = transform.transform(point);

			float x = TileBoundingBoxUtils.getXPixel(tileWidth, boundingBox,
					projectedPoint.getX());
			float y = TileBoundingBoxUtils.getYPixel(tileHeight, boundingBox,
					projectedPoint.getY());

			if (path == null) {
				path = new Path2D.Double();
				path.moveTo(x, y);
			} else {
				path.lineTo(x, y);
			}

		}

		return path;
	}
1272855
function generatePathString(paths) {
  let pathString = '';

  if (!paths || !paths.length) return pathString;

  if (paths.length > 1) {
    pathString = paths.map(pathItem => filepathName(pathItem));
    // Trim long lists
    if (pathString.length > maxInputStringLength) {
      const remainder = pathString.length - maxInputStringLength;

      pathString = `${pathString
        .slice(0, maxInputStringLength)
        .join(', ')} ...and ${remainder} other${remainder > 1 ? 's' : ''}`;
    } else {
      pathString = pathString.join(', ');
    }
  } else {
    pathString = filepathName(paths[0]);
  }

  return pathString;
}
523684
function transformFile ({ config, entry, outdir }) {
  const filename = entry[0]
  const filepath = entry[1] || `${outdir}/${filename}`
  const results = babel.transform(
    fs.readFileSync(filename, 'utf8'),
    Object.assign({}, config, { filename, sourceMaps: true })
  )
  mkdirp.sync(path.dirname(filepath))
  fs.writeFileSync(
    filepath,
    results.code + '\n\n//# sourceMappingURL=' + path.basename(filepath)
  )
  fs.writeFileSync(`${filepath}.map`, JSON.stringify(results.map))

  return results
}
1033033
def fit_transform_poof(self, X, y=None, outpath=None, **kwargs):
        
        self.fit_transform(X, y, **kwargs)
        self.poof(outpath, **kwargs)
636061
function getMiddlePaths(paths, ext, new_ext) {

	if (Array.isArray(paths)) {
		return paths.map(function eachEntry(entry) {
			return getMiddlePaths(entry, ext, new_ext);
		});
	}

	if (ext && new_ext) {
		paths = paths.replace(ext, new_ext);
	}

	return paths;
}
712828
def _iter_path_collection(paths, path_transforms, offsets, styles):
        """"""
        N = max(len(paths), len(offsets))

        if not path_transforms:
            path_transforms = [np.eye(3)]

        edgecolor = styles['edgecolor']
        if np.size(edgecolor) == 0:
            edgecolor = ['none']
        facecolor = styles['facecolor']
        if np.size(facecolor) == 0:
            facecolor = ['none']

        elements = [paths, path_transforms, offsets,
                    edgecolor, styles['linewidth'], facecolor]

        it = itertools
        return it.islice(py3k.zip(*py3k.map(it.cycle, elements)), N)
59505
function formatPath(pattern, path) {
    let prefix = pattern.replace(/(\/\*\*|\/\*)/g, '');
    return path.replace(prefix, '').replace(/(\/[a-zA-Z-_]+)/, '$1' + prefix);
  }
790829
def add_path(self, w, h):
        """"""
        custGeom = self.spPr.custGeom
        if custGeom is None:
            raise ValueError('shape must be freeform')
        pathLst = custGeom.get_or_add_pathLst()
        return pathLst.add_path(w=w, h=h)
419036
public void applyToPath(Matrix transform, Path path) {
        for (int i = 0, size = operations.size(); i < size; i++) {
            PathOperation operation = operations.get(i);
            operation.applyToPath(transform, path);
        }
    }
1289339
def join_paths(fnames:FilePathList, path:PathOrStr='.')->Collection[Path]:
    ""
    path = Path(path)
    return [join_path(o,path) for o in fnames]
67629
def expand_path(*paths):
    """"""
    return os.path.join(
        os.path.dirname(os.path.realpath(sys.argv[0])), *paths)
732084
def _expand_paths_itr(paths, marker='*'):
    
    for path in paths:
        if is_path(path):
            if marker in path:  # glob path pattern
                for ppath in sglob(path):
                    yield ppath
            else:
                yield path  # a simple file path
        elif is_path_obj(path):
            if marker in path.as_posix():
                for ppath in sglob(path.as_posix()):
                    yield normpath(ppath)
            else:
                yield normpath(path.as_posix())
        elif is_ioinfo(path):
            yield path.path
        else:  # A file or file-like object
            yield path