code: def private_key_to_address(self, pk):
          
          pub = privtopub(pk)
          pub_byte, priv_byte = get_magic_bytes(self.crypto)
  
          if priv_byte >= 128:
              priv_byte -= 128 #pybitcointools bug
  
          return pubtoaddr(pub, pub_byte)
docs: Convert a private key (in hex format) into an address.