def init_with_seed(seed, network: nil)
      hmac = BTC.hmac_sha512(data: seed, key: "Bitcoin seed".encode(Encoding::ASCII))
      @private_key = hmac[0,32]
      @public_key = BTC::Key.new(private_key: @private_key, public_key_compressed: true).public_key
      @chain_code = hmac[32,32]
      @fingerprint = nil
      @parent_fingerprint = 0
      @index = 0
      @depth = 0
      @network = network || BTC::Network.default
    end
def init_with_seed(seed, network: nil)
      hmac = BTC.hmac_sha512(data: seed, key: "Bitcoin seed".encode(Encoding::ASCII))
      @private_key = hmac[0,32]
      @public_key = BTC::Key.new(private_key: @private_key, public_key_compressed: true).public_key
      @chain_code = hmac[32,32]
      @fingerprint = nil
      @parent_fingerprint = 0
      @index = 0
      @depth = 0
      @network = network || BTC::Network.default
    end
Instantiates Keychain with a binary seed or a base58-encoded extended public/private key.
 Usage:
 * Keychain.new(seed: ...[, network: ...])
 * Keychain.new(extended_key: "xpub..." or "xprv...")
 * Keychain.new(xpub: "xpub...")
 * Keychain.new(xprv: "xprv...")