cratepy.ioput.packager.store_clustering_data

store_clustering_data(clustering_solution_method, standardization_method, phase_n_clusters, rg_dict, clustering_type, base_clustering_scheme, adaptive_clustering_scheme, adapt_criterion_data, adaptivity_type, adaptivity_control_feature, clust_adapt_freq, is_clust_adapt_output, is_store_final_clustering)[source]

Store data associated with the clustering-based domain decomposition.

Parameters:
  • clustering_solution_method (int) – Identifier of DNS homogenization-based multi-scale DNS method to compute the clustering features data.

  • standardization_method (int) – Identifier of global cluster analysis data standardization algorithm.

  • phase_n_clusters (dict) – Number of clusters (item, int) prescribed for each material phase (key, str).

  • rg_dict (dict) – Container.

  • clustering_type (str) – Type of cluster-reduced material phase.

  • base_clustering_scheme (dict) – Prescribed base clustering scheme (item, numpy.ndarray of shape (n_clusterings, 3)) for each material phase (key, str). Each row is associated with a unique clustering characterized by a clustering algorithm (col 1, int), a list of features (col 2, list[int]) and a list of the features data matrix’ indexes (col 3, list[int]).

  • adaptive_clustering_scheme (dict) – Prescribed adaptive clustering scheme (item, numpy.ndarray of shape (n_clusterings, 3)) for each material phase (key, str). Each row is associated with a unique clustering characterized by a clustering algorithm (col 1, int), a list of features (col 2, list[int]) and a list of the features data matrix’ indexes (col 3, list[int]).

  • adapt_criterion_data (dict) – Clustering adaptivity criterion (item, dict) associated with each material phase (key, str). This dictionary contains the adaptivity criterion to be used and the required parameters.

  • adaptivity_type (dict) – Clustering adaptivity type (item, dict) associated with each material phase (key, str). This dictionary contains the adaptivity type to be used and the required parameters.

  • adaptivity_control_feature (dict) – Clustering adaptivity control feature (item, str) associated with each material phase (key, str).

  • clust_adapt_freq (dict) – Clustering adaptivity frequency (relative to the macroscale loading) (item, int, default=1) associated with each adaptive cluster-reduced material phase (key, str).

  • is_clust_adapt_output (bool) – Clustering adaptivity output flag.

  • is_store_final_clustering (bool) – True to store CRVE final clustering state into file, False otherwise.

Returns:

clst_dict – Container.

Return type:

dict