def dgl_partition_to_graphbolt(
    part_config,
    *,
    store_eids=True,
    store_inner_node=False,
    store_inner_edge=False,
    graph_formats=None,
    n_jobs=1,
):
    """Convert partitions of dgl to FusedCSCSamplingGraph of GraphBolt.

    This API converts `DGLGraph` partitions to `FusedCSCSamplingGraph` which is
    dedicated for sampling in `GraphBolt`. New graphs will be stored alongside
    original graph as `fused_csc_sampling_graph.pt`.

    In the near future, partitions are supposed to be saved as
    `FusedCSCSamplingGraph` directly. At that time, this API should be deprecated.

    Parameters
    ----------
    part_config : str
        The partition configuration JSON file.
    store_eids : bool, optional
        Whether to store edge IDs in the new graph. Default: True.
    store_inner_node : bool, optional
        Whether to store inner node mask in the new graph. Default: False.
    store_inner_edge : bool, optional
        Whether to store inner edge mask in the new graph. Default: False.
    graph_formats : str or list[str], optional
        Save partitions in specified formats. It could be any combination of
        `coo`, `csc`. As `csc` format is mandatory for `FusedCSCSamplingGraph`,
        it is not necessary to specify this argument. It's mainly for
        specifying `coo` format to save edge ID mapping and destination node
        IDs. If not specified, whether to save `coo` format is determined by
        the availability of the format in DGL partitions. Default: None.
    n_jobs: int
        Number of parallel jobs to run during partition conversion. Max parallelism
        is determined by the partition count.
    """
    debug_mode = "DGL_DIST_DEBUG" in os.environ
    if debug_mode:
        dgl_warning(
            "Running in debug mode which means all attributes of DGL partitions"
            " will be saved to the new format."
        )
    part_meta = _load_part_config(part_config)
    num_parts = part_meta["num_parts"]
    part_meta = _convert_partition_to_graphbolt_wrapper(
        graph_formats=graph_formats,
        part_config=part_config,
        store_eids=store_eids,
        store_inner_node=store_inner_node,
        store_inner_edge=store_inner_edge,
        n_jobs=n_jobs,
        num_parts=num_parts,
    )
    _dump_part_config(part_config, part_meta)
Convert partitions of dgl to FusedCSCSamplingGraph of GraphBolt.

    This API converts `DGLGraph` partitions to `FusedCSCSamplingGraph` which is
    dedicated for sampling in `GraphBolt`. New graphs will be stored alongside
    original graph as `fused_csc_sampling_graph.pt`.

    In the near future, partitions are supposed to be saved as
    `FusedCSCSamplingGraph` directly. At that time, this API should be deprecated.

    Parameters
    ----------
    part_config : str
        The partition configuration JSON file.
    store_eids : bool, optional
        Whether to store edge IDs in the new graph. Default: True.
    store_inner_node : bool, optional
        Whether to store inner node mask in the new graph. Default: False.
    store_inner_edge : bool, optional
        Whether to store inner edge mask in the new graph. Default: False.
    graph_formats : str or list[str], optional
        Save partitions in specified formats. It could be any combination of
        `coo`, `csc`. As `csc` format is mandatory for `FusedCSCSamplingGraph`,
        it is not necessary to specify this argument. It's mainly for
        specifying `coo` format to save edge ID mapping and destination node
        IDs. If not specified, whether to save `coo` format is determined by
        the availability of the format in DGL partitions. Default: None.
    n_jobs: int
        Number of parallel jobs to run during partition conversion. Max parallelism
        is determined by the partition count.
    
python/dgl/distributed/partition.py