code: def from_protobuf(cls, peer_info_pb: p2pd_pb2.PeerInfo) -> "PeerInfo":
      peer_id = PeerID(peer_info_pb.id)
      addrs = [Multiaddr(addr) for addr in peer_info_pb.addrs]
      return PeerInfo(peer_id, addrs)
  
imports: import hashlib
  from typing import Any, Sequence, Union
  import base58
  import multihash
  from cryptography.hazmat.primitives import serialization
  from multiaddr import Multiaddr, protocols
  from hivemind.proto import crypto_pb2, p2pd_pb2
label_desc: Use image node_id 3 for calling the PeerInfo obj's underlying member method code with example usage: obj.from_protobuf(cls, peer_info_pb) and returns: PeerInfo