docs: def bin_hash160(s, hex_format=False):
      """ s is in hex or binary format
      """
      if hex_format and is_hex(s):
          s = unhexlify(s)
      return hashlib.new('ripemd160', bin_sha256(s)).digest()