fn generate_labels_for_encoding(
        graph: &StackedBucketGraph<Tree::Hasher>,
        layer_challenges: &LayerChallenges,
        replica_id: &<Tree::Hasher as Hasher>::Domain,
        config: StoreConfig,
    ) -> Result<(Labels<Tree>, Vec<LayerState>)> {
        let mut parent_cache = graph.parent_cache()?;

        if settings::SETTINGS.use_multicore_sdr {
            info!("multi core replication");
            create_label::multi::create_labels_for_encoding(
                graph,
                &parent_cache,
                layer_challenges.layers(),
                replica_id,
                config,
            )
        } else {
            info!("single core replication");
            create_label::single::create_labels_for_encoding(
                graph,
                &mut parent_cache,
                layer_challenges.layers(),
                replica_id,
                config,
            )
        }
    }
/// Generates the layers as needed for encoding.
Generates the layers as needed for encoding.
Generates the layers as needed for encoding .
fn generate_labels_for_encoding(
        graph: &StackedBucketGraph<Tree::Hasher>,
        layer_challenges: &LayerChallenges,
        replica_id: &<Tree::Hasher as Hasher>::Domain,
        config: StoreConfig,
    ) -> Result<(Labels<Tree>, Vec<LayerState>)> {
        let mut parent_cache = graph.parent_cache()?;
        if settings::SETTINGS.use_multicore_sdr {
            info!("multi core replication");
            create_label::multi::create_labels_for_encoding(
                graph,
                &parent_cache,
                layer_challenges.layers(),
                replica_id,
                config,
            )
        } else {
            info!("single core replication");
            create_label::single::create_labels_for_encoding(
                graph,
                &mut parent_cache,
                layer_challenges.layers(),
                replica_id,
                config,
            )
        }
    }
fn generate_labels_for_encoding ( graph : & StackedBucketGraph < Tree :: Hasher > , layer_challenges : & LayerChallenges , replica_id : & < Tree :: Hasher as Hasher > :: Domain , config : StoreConfig , ) -> Result < ( Labels < Tree > , Vec < LayerState > ) > { let mut parent_cache = graph . parent_cache ( ) ? ; if settings :: SETTINGS . use_multicore_sdr { info ! ( " " ) ; create_label :: multi :: create_labels_for_encoding ( graph , & parent_cache , layer_challenges . layers ( ) , replica_id , config , ) } else { info ! ( " " ) ; create_label :: single :: create_labels_for_encoding ( graph , & mut parent_cache , layer_challenges . layers ( ) , replica_id , config , ) } }
Generates the layers as needed for encoding.
Generates the layers as needed for encoding .
graph
&StackedBucketGraph<Tree::Hasher>
layer_challenges
&LayerChallenges
replica_id
&<Tree::Hasher as Hasher>::Domain
config
StoreConfig
graph
&StackedBucketGraph<Tree::Hasher>
layer_challenges
&LayerChallenges
replica_id
&<Tree::Hasher as Hasher>::Domain
config
StoreConfig