class_docstr: A simple parameter server. Clients can store tensors, accumulate, and
  get tensors by string key. Operations on the parameter server are globally
  synchronous.
  
  FIXME: torchbiggraph.rpc should be fixed to not require torch.serialization,
  then most of this code can be removed.
  FIXME: torch.distributed.recv should not require you to provide the
  tensor to write to; the type and size should be sent in the header.
  That would simplify this code a lot.
class_docstr_tok: ["A","simple","parameter","server",".","Clients","can","store","tensors",",","accumulate",",","and","get","tensors","by","string","key",".","Operations","on","the","parameter","server","are","globally","synchronous",".","FIXME",":","torchbiggraph.rpc","should","be","fixed","to","not","require","torch.serialization",",","then","most","of","this","code","can","be","removed",".","FIXME",":","torch.distributed.recv","should","not","require","you","to","provide","the","tensor","to","write","to",";","the","type","and","size","should","be","sent","in","the","header",".","That","would","simplify","this","code","a","lot","."]
docstr: Receive a string tensor key from a client node.
code: def _recv_key(
      rank: int, keylen: int, group: Optional["td.ProcessGroup"] = None
  ) -> str:
      """Receive a string tensor key from a client node."""
      key_buffer = torch.zeros((keylen,), dtype=torch.int8)
      td.recv(key_buffer, src=rank, group=group)
      return _tostring(key_buffer)
  
imports: import logging
  import multiprocessing
  import queue
  import time
  import traceback
  from functools import lru_cache
  from typing import Callable, Dict, List, Optional, Sequence
  import torch
  import torch.distributed
  import torch.multiprocessing
  from torchbiggraph.distributed import init_process_group, Startable
  from torchbiggraph.types import CharTensorType, Rank
  from torchbiggraph.util import allocate_shared_tensor, split_almost_equally, tag_logs_with_process_name
label_desc: Use image node_id 5 for calling the ParameterServer obj's underlying member method code with example usage: obj._recv_key(rank, keylen, group) and returns: _tostring