Inverse of escape.
558657
def unescape(value):
    
    pattern = ESCAPE_FMT.replace('%02X', '(?P<code>[0-9A-Fa-f]{2})')
    # the pattern must be bytes to operate on bytes
    pattern_bytes = pattern.encode('ascii')
    re_esc = re.compile(pattern_bytes)
    return re_esc.sub(_unescape_code, value.encode('ascii')).decode('utf-8')
153136
def Escape(self, string="", **_):
    """"""
    # Translate special escapes:
    self.stack[-1] += self.STRING_ESCAPES.get(string, string)
121268
def do_forceescape(value):
    """"""
    if hasattr(value, '__html__'):
        value = value.__html__()
    return escape(unicode(value))
1373905
function escapeDelimiters(pattern, text) {
  return text.replace(pattern, (match, start, end) => {
    const hasEnd = typeof end === 'string';
    const matchSliceEnd = hasEnd ? match.length - end.length : match.length;
    const content = match.slice(start.length, matchSliceEnd);
    return `${escape(start)}${content}${hasEnd ? escape(end) : ''}`;
  });
}
1041140
def escape(self, varname, value):
        
        f = self.escape_funcs.get(varname)
        return f(value) if f else value
711797
def inverse(self):
        
        result = G2Element()
        librelic.g2_neg_abi(byref(result), byref(self))
        return result
724647
static void escape(final char[] text, final int offset, final int len, final Writer writer)
                       throws IOException {

        if (text == null || text.length == 0) {
            return;
        }

        final int max = (offset + len);

        int readOffset = offset;

        for (int i = offset; i < max; i++) {

            final char c = text[i];


            /*
             * Shortcut: most characters will be Alphanumeric, and we won't need to do anything at
             * all for them.
             */
            if ((c >= 'a' && c <= 'z') || (c >= 'A' && c <= 'Z') || (c >= '0' && c <= '9')) {
                continue;
            }


            /*
             * At this point we know for sure we will need some kind of escape, so we
             * initialize the string builder.
             */
            if (readOffset == offset) {
                // If we need this, it's because we have non-alphanumeric chars. And that means
                // we should enclose in double-quotes.
                writer.write(DOUBLE_QUOTE);
            }

            /*
             * Now we copy all the contents pending up to this point.
             */
            if (i - readOffset > 0) {
                writer.write(text, readOffset, (i - readOffset));
            }

            readOffset = i + 1;

            /*
             * Check whether the character is a double-quote (in which case, we escape it)
             */
            if (c == DOUBLE_QUOTE) {
                writer.write(TWO_DOUBLE_QUOTES);
                continue;
            }

            writer.write(c);

        }


        /*
         * -----------------------------------------------------------------------------------------------
         * Final cleaning: append the remaining unescaped text to the string builder and return.
         * -----------------------------------------------------------------------------------------------
         */

        if (max - readOffset > 0) {
            writer.write(text, readOffset, (max - readOffset));
        }

        if (readOffset > offset) {
            // If we reached here, it's because we had non-alphanumeric chars. And that means
            // we should enclose in double-quotes.
            writer.write(DOUBLE_QUOTE);
        }

    }
1038713
def inverse(self, encoded, duration=None):
        ''''''

        ann = jams.Annotation(namespace=self.namespace, duration=duration)
        for start, end, value in self.decode_intervals(encoded,
                                                       duration=duration,
                                                       transition=self.transition,
                                                       p_init=self.p_init,
                                                       p_state=self.p_state):
            # Map start:end to frames
            f_start, f_end = time_to_frames([start, end],
                                            sr=self.sr,
                                            hop_length=self.hop_length)

            confidence = np.mean(encoded[f_start:f_end+1, value])

            value_dec = self.encoder.inverse_transform(np.atleast_2d(value))[0]

            for vd in value_dec:
                ann.append(time=start,
                           duration=end-start,
                           value=vd,
                           confidence=confidence)

        return ann
166805
public final void inverse() {
		double norm;  

		norm = 1f/(this.w*this.w + this.x*this.x + this.y*this.y + this.z*this.z);
		this.w *=  norm;
		this.x *= -norm;
		this.y *= -norm;
		this.z *= -norm;
	}
564033
function escape (string) {
  return string
    .replace(/ /g, '\\ ')
    .replace(/\n/g, '')
    .replace(/\(/g, '\\(')
    .replace(/\)/g, '\\)');
}
304766
def replace_escapes(self, m):
        """"""

        groups = m.groupdict()
        esc = m.group(0)
        if groups.get('special'):
            value = BACK_SLASH_TRANSLATION[esc]
        elif groups.get('char'):
            try:
                if esc.endswith('}'):
                    value = chr(int(esc[3:-1], 16))
                else:
                    value = chr(int(esc[2:], 16))
            except Exception:
                value = esc
        elif groups.get('oct'):
            # JavaScript only supports hex range.
            # So \400 would be \40 + '0'
            value = int(esc[1:], 8)
            overflow = ''
            if value > 255:
                value = esc[1:-1]
                overflow + esc[-1]
            value = chr(value) + overflow
        elif('other'):
            value = esc[1:]
        return value.replace('\x00', '\n')
1351793
private static String escape(String string) {
    return StringUtils.escapeString(string, StringUtils.ESCAPE_CHAR, 
                                    charsToEscape);
  }
79032
def escape(cls, s):
        
        rv = escape(s)
        if rv.__class__ is not cls:
            return cls(rv)
        return rv
601893
function unescape (line) {
  var retv = _.replace(line, propEscapeRE, '$1');
  retv = _.replace(line, unicodeEscapeRE, function (m) {
    return String.fromCharCode(parseInt(m, 16));
  });
  if (retv !== line) {
    debug('removed escapes from: %s => %s', line, retv);
  }
  return retv;
}
1051165
function reverse(param) {
    var ret = new buffer.Buffer(param.length);
    for (var i = 0; i < param.length; i++) {
      ret[i] = param[param.length - i - 1];
    }
    return ret;
  }
322427
def escape(arg):
    "" 
    slash = '\\'
    special = '"$'

    arg = arg.replace(slash, slash+slash)
    for c in special:
        arg = arg.replace(c, slash+c)

    # print("ESCAPE RESULT: %s" % arg)
    return '"' + arg + '"'
67413
def escape(self):
        
        if self._escape is not None:
            return self._escape
        if self._default_escape is not None:
            return self._default_escape
        return True