class_docstr: This class implements the :class:`torch_geometric.data.FeatureStore`
  interface to act as a local feature store for distributed training.
docstr: Creates a local feature store from homogeneous :pyg:`PyG` tensors.
  
  Args:
      node_id (torch.Tensor): The global identifier for every local node.
      x (torch.Tensor, optional): The node features.
          (default: :obj:`None`)
      y (torch.Tensor, optional): The node labels. (default: :obj:`None`)
      edge_id (torch.Tensor, optional): The global identifier for every
          local edge. (default: :obj:`None`)
      edge_attr (torch.Tensor, optional): The edge features.
          (default: :obj:`None`)
docstr_tok: ["Creates","a","local","feature","store","from","homogeneous",":","pyg",":","`","PyG","`","tensors",".","Args",":","node_id","(","torch.Tensor",")",":","The","global","identifier","for","every","local","node",".","x","(","torch.Tensor",",","optional",")",":","The","node","features",".","(","default",":",":","obj",":","`","None","`",")","y","(","torch.Tensor",",","optional",")",":","The","node","labels",".","(","default",":",":","obj",":","`","None","`",")","edge_id","(","torch.Tensor",",","optional",")",":","The","global","identifier","for","every","local","edge",".","(","default",":",":","obj",":","`","None","`",")","edge_attr","(","torch.Tensor",",","optional",")",":","The","edge","features",".","(","default",":",":","obj",":","`","None","`",")"]
code: def from_data(
      cls,
      node_id: Tensor,
      x: Optional[Tensor] = None,
      y: Optional[Tensor] = None,
      edge_id: Optional[Tensor] = None,
      edge_attr: Optional[Tensor] = None,
  ) -> "LocalFeatureStore":
      r"""Creates a local feature store from homogeneous :pyg:`PyG` tensors.
  
      Args:
          node_id (torch.Tensor): The global identifier for every local node.
          x (torch.Tensor, optional): The node features.
              (default: :obj:`None`)
          y (torch.Tensor, optional): The node labels. (default: :obj:`None`)
          edge_id (torch.Tensor, optional): The global identifier for every
              local edge. (default: :obj:`None`)
          edge_attr (torch.Tensor, optional): The edge features.
              (default: :obj:`None`)
      """
      feat_store = cls()
      feat_store.put_global_id(node_id, group_name=None)
      if x is not None:
          feat_store.put_tensor(x, group_name=None, attr_name="x")
      if y is not None:
          feat_store.put_tensor(y, group_name=None, attr_name="y")
      if edge_id is not None:
          feat_store.put_global_id(edge_id, group_name=(None, None))
      if edge_attr is not None:
          if edge_id is None:
              raise ValueError(
                  "'edge_id' needs to be present in case "
                  "'edge_attr' is passed"
              )
          feat_store.put_tensor(
              edge_attr, group_name=(None, None), attr_name="edge_attr"
          )
      return feat_store
  
imports: import copy
  import json
  import os.path
  from dataclasses import dataclass
  from typing import Any, Dict, List, Optional, Tuple, Union
  import torch
  from torch import Tensor
  from torch_geometric.data import FeatureStore, TensorAttr
  from torch_geometric.data.feature_store import _FieldStatus
  from torch_geometric.distributed.rpc import RPCCallBase, RPCRouter, rpc_async, rpc_register
  from torch_geometric.typing import EdgeType, NodeOrEdgeType, NodeType
label_desc: Use image node_id 19 for calling the LocalFeatureStore obj's underlying member method code with example usage: obj.from_data(cls, node_id, x, y, edge_id, edge_attr) and returns: feat_store