tgraphx 1.3.1__tar.gz → 1.3.2__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {tgraphx-1.3.1/tgraphx.egg-info → tgraphx-1.3.2}/PKG-INFO +3 -1
- {tgraphx-1.3.1 → tgraphx-1.3.2}/README.md +2 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/pyproject.toml +1 -1
- tgraphx-1.3.2/tests/test_evolutionary_history_v132.py +125 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/__init__.py +1 -1
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/evolutionary/algorithms.py +104 -7
- {tgraphx-1.3.1 → tgraphx-1.3.2/tgraphx.egg-info}/PKG-INFO +3 -1
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx.egg-info/SOURCES.txt +1 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/LICENSE +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/setup.cfg +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_3d_support.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_algorithms.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_amp_compile.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_api_stability_labels.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_backward_compatibility.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_benchmark_smoke.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_calibration.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_chunking.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_cluster_gcn.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_continuous_rl_algorithms.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_dashboard.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_dashboard_metadata.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_dataset_cache.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_dataset_docs_claims.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_dataset_download_mocked.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_dataset_registry.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_datasets_base.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_devices.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_distributed_compat.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_distributed_helpers.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_distributed_smoke.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_documentation_claims.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_edge_features.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_edge_weight.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_estimators_v05.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_evolutionary_graph_optimization.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_experiments.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_explainability.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_factories.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_folder_datasets.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_gat_chunking.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_generation_rl_benchmarks_smoke.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_gnn_families.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_gradients.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_graph.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_graph_action_spaces.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_graph_api.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_graph_builders.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_graph_generation_data_model.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_graph_generation_metrics.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_graph_rl_algorithms.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_graph_rl_environments.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_graph_transformer_v027.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_graph_utils.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_graphsaint.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_han_hgt_overfit.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_hard_negative_sampling.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_hetero_batch.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_hetero_layers.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_hetero_layers_v05.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_hetero_sampling.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_imports.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_io_graphml_v120.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_kg_benchmarks_smoke.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_kg_data_model.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_kg_datasets.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_kg_evaluation.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_kg_feature_aware_v131.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_kg_gnn_integration.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_kg_hpo_v130.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_kg_models.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_kg_multimodal.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_kg_negative_sampling.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_kg_reasoning.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_kg_rescal_v120.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_kg_simple_v130.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_kg_temporal.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_kg_training.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_layers.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_loader_feature_store_integration.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_loader_robustness_v110.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_loaders_feature_store.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_matching_coloring_flow.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_math.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_math_correctness_v110.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_math_invariants_v030.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_metrics.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_mining_centrality.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_mining_core.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_mining_generators_spectral.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_mining_graph_learning.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_mining_paths_algorithms.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_mining_structural.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_model_zoo.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_models.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_negative_sampling.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_neural_mining.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_neural_mining_batched.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_node2vec_kg_hypergraph.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_notebooks_v130.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_ogb_tgb_wrappers.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_packaging.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_performance_smoke.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_plotting.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_public_benchmarks.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_pyg_dgl_ogb_wrappers.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_random_walk_sample.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_readme_links.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_release_validation_v030.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_reproducibility.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_rl_baselines.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_rl_callbacks_v120.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_rl_high_level_api.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_rollout_buffer.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_sampling.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_sampling_loaders.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_sparse_backend_select.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_sparse_vgae_rgcn.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_synthetic_datasets.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_temporal_sampling.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_temporal_v025.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_temporal_v05.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_tgn_tgat_overfit.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_time_encoding.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_tiny_overfit_v030.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_torchvision_wrappers.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_tracking.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_training.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_transforms.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_user_friendly_llm_snippets.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tests/test_v024_features.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/__main__.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/algorithms/__init__.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/algorithms/connectivity.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/algorithms/structural.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/algorithms/traversal.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/benchmarks/__init__.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/benchmarks/public.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/calibration.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/cluster_gcn.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/core/__init__.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/core/dataloader.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/core/graph.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/core/graph_utils.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/core/hetero_batch.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/core/hetero_graph.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/core/temporal.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/core/temporal_batch.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/core/utils.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/dashboard/__init__.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/dashboard/__main__.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/dashboard/app.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/dashboard/static/dashboard.css +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/dashboard/static/dashboard.js +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/datasets/__init__.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/datasets/base.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/datasets/cache.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/datasets/converters.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/datasets/dgl_wrappers.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/datasets/download.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/datasets/errors.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/datasets/folder.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/datasets/metadata.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/datasets/ogb_wrappers.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/datasets/pyg_wrappers.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/datasets/registry.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/datasets/synthetic.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/datasets/torchvision_wrappers.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/distributed.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/doctor.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/easy/__init__.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/easy/_data.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/easy/_diagnostics.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/easy/_discovery.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/easy/_exceptions.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/easy/_models.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/easy/_results.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/easy/_workflows.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/estimators/__init__.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/estimators/base.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/estimators/early_stopping.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/estimators/label_propagation.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/estimators/node2vec.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/estimators/splits.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/estimators/vgae.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/evolutionary/__init__.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/evolutionary/config.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/evolutionary/fitness.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/evolutionary/genome.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/evolutionary/high_level_api.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/evolutionary/metrics.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/evolutionary/multi_objective.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/evolutionary/operators.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/evolutionary/reports.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/evolutionary/selection.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/experiments/__init__.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/experiments/callbacks.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/experiments/checkpoints.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/experiments/cli.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/experiments/config.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/experiments/grid.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/experiments/runner.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/experiments/summarize.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/explain/__init__.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/explain/attention.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/explain/edge_attribution.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/explain/export.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/explain/integrated_gradients.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/explain/patch_heatmap.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/explain/saliency.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/explain/utils.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/feature_store.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/generation/__init__.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/generation/actions.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/generation/classical.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/generation/config.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/generation/data_model.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/generation/high_level_api.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/generation/metrics.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/generation/neural.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/generation/projectors.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/generation/reports.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/graph_builders.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/graphsaint.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/hetero_sampling.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/interop.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/io/__init__.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/io/graphml.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/kg/__init__.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/kg/data.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/kg/datasets.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/kg/evaluation.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/kg/gnn.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/kg/hpo.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/kg/losses.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/kg/models.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/kg/multimodal.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/kg/projectors.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/kg/reasoning.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/kg/reports.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/kg/sampling.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/kg/temporal.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/kg/trainer.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/layers/__init__.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/layers/_dim.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/layers/_scatter.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/layers/aggregator.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/layers/appnp.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/layers/attention_message.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/layers/base.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/layers/conv_message.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/layers/factory.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/layers/gat.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/layers/gatv2.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/layers/gin.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/layers/graph_transformer.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/layers/han.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/layers/hetero.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/layers/hetero_readout.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/layers/hgt.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/layers/pooling.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/layers/rgcn.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/layers/safe_pool.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/layers/sage.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/layers/temporal_readout.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/layers/transformer_encodings.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/layers/vector_gcn.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/learned_graph.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/loaders.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/metrics/__init__.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/metrics/classification.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/metrics/link_prediction.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/metrics/ogb.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/metrics/ranking.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/metrics/regression.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/metrics/reports.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/mining/__init__.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/mining/anomaly.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/mining/api.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/mining/centrality.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/mining/communities.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/mining/embeddings.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/mining/frequent.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/mining/generators.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/mining/graph_io.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/mining/graph_learning.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/mining/hetero.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/mining/hypergraph.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/mining/kernels.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/mining/knowledge_graph.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/mining/label_prop.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/mining/link_prediction.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/mining/matching_coloring.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/mining/motifs.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/mining/neural.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/mining/node2vec.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/mining/paths.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/mining/patterns.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/mining/prototype.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/mining/random_walk.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/mining/reports.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/mining/sequence_models.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/mining/similarity.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/mining/spectral.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/mining/structural.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/mining/structural_encodings.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/mining/temporal.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/mining/vgae.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/models/__init__.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/models/cnn_encoder.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/models/cnn_gnn_model.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/models/edge_predictor.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/models/factory.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/models/graph_classifier.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/models/hetero_models.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/models/model_zoo.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/models/node_classifier.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/models/pre_encoder.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/models/regressors.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/models/temporal_models.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/performance.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/plotting/__init__.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/plotting/graph.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/plotting/layouts.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/plotting/mining.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/plotting/utils.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/reproducibility.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/rl/__init__.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/rl/algorithms/__init__.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/rl/algorithms/actor_critic.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/rl/algorithms/base.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/rl/algorithms/baselines.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/rl/algorithms/continuous.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/rl/algorithms/dqn.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/rl/algorithms/ppo.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/rl/algorithms/reinforce.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/rl/algorithms/replay_buffer.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/rl/callbacks.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/rl/config.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/rl/environments/__init__.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/rl/environments/base.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/rl/environments/coloring.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/rl/environments/continuous.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/rl/environments/generation.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/rl/environments/kg_reasoning.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/rl/environments/max_cut.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/rl/environments/navigation.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/rl/environments/shortest_path.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/rl/environments/vertex_cover.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/rl/exploration/__init__.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/rl/exploration/strategies.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/rl/high_level_api.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/rl/metrics.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/rl/networks/__init__.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/rl/networks/actor_critic.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/rl/networks/policy.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/rl/networks/projectors.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/rl/networks/qnetwork.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/rl/networks/value.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/rl/reports.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/sampling.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/sampling_loaders.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/sampling_negative.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/sparse.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/temporal/__init__.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/temporal/tgat.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/temporal/tgn.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/temporal/time_encoding.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/temporal_sampling.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/tracking.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/training.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/transforms/__init__.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/transforms/compose.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/transforms/features.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/transforms/graph.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/transforms/patch.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/transforms/positional.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx/transforms/splits.py +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx.egg-info/dependency_links.txt +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx.egg-info/entry_points.txt +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx.egg-info/requires.txt +0 -0
- {tgraphx-1.3.1 → tgraphx-1.3.2}/tgraphx.egg-info/top_level.txt +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: tgraphx
|
|
3
|
-
Version: 1.3.
|
|
3
|
+
Version: 1.3.2
|
|
4
4
|
Summary: Tensor-aware graph neural networks preserving spatial node feature layouts
|
|
5
5
|
Author-email: Arash Sajjadi <arash.sajjadi@usask.ca>
|
|
6
6
|
Maintainer-email: Arash Sajjadi <arash.sajjadi@usask.ca>
|
|
@@ -198,6 +198,8 @@ out.sum().backward()
|
|
|
198
198
|
A Colab tutorial walks through every workflow:
|
|
199
199
|
[](https://colab.research.google.com/drive/1agls1xtqE5WxbWthcG0HEa3Gbk3fvoCD?usp=sharing)
|
|
200
200
|
|
|
201
|
+
**Notebook gallery:** 13 scenario-driven notebooks covering Easy Mode, tensor-native image-patch graphs, sampling, knowledge graphs (including KG HPO and multimodal entity features), and graph generation are available in [docs/colab_gallery.md](docs/colab_gallery.md).
|
|
202
|
+
|
|
201
203
|
---
|
|
202
204
|
|
|
203
205
|
## Capability map
|
|
@@ -143,6 +143,8 @@ out.sum().backward()
|
|
|
143
143
|
A Colab tutorial walks through every workflow:
|
|
144
144
|
[](https://colab.research.google.com/drive/1agls1xtqE5WxbWthcG0HEa3Gbk3fvoCD?usp=sharing)
|
|
145
145
|
|
|
146
|
+
**Notebook gallery:** 13 scenario-driven notebooks covering Easy Mode, tensor-native image-patch graphs, sampling, knowledge graphs (including KG HPO and multimodal entity features), and graph generation are available in [docs/colab_gallery.md](docs/colab_gallery.md).
|
|
147
|
+
|
|
146
148
|
---
|
|
147
149
|
|
|
148
150
|
## Capability map
|
|
@@ -5,7 +5,7 @@ build-backend = "setuptools.build_meta"
|
|
|
5
5
|
[project]
|
|
6
6
|
name = "tgraphx"
|
|
7
7
|
# Keep this in sync with tgraphx/__init__.py::__version__
|
|
8
|
-
version = "1.3.
|
|
8
|
+
version = "1.3.2"
|
|
9
9
|
description = "Tensor-aware graph neural networks preserving spatial node feature layouts"
|
|
10
10
|
readme = "README.md"
|
|
11
11
|
requires-python = ">=3.10"
|
|
@@ -0,0 +1,125 @@
|
|
|
1
|
+
"""Regression tests for EvolutionResult.history (v1.3.2 bugfix).
|
|
2
|
+
|
|
3
|
+
Bug fixed: EvolutionResult had no `history` attribute, causing AttributeError
|
|
4
|
+
when users accessed `result.history` after optimization.
|
|
5
|
+
"""
|
|
6
|
+
from __future__ import annotations
|
|
7
|
+
import json
|
|
8
|
+
import pytest
|
|
9
|
+
import torch
|
|
10
|
+
|
|
11
|
+
from tgraphx.evolutionary import (
|
|
12
|
+
GraphGenome, GeneticAlgorithmOptimizer, GeneticAlgorithmConfig,
|
|
13
|
+
NSGAIIOptimizer, EvolutionConfig, connectivity_fitness,
|
|
14
|
+
)
|
|
15
|
+
|
|
16
|
+
|
|
17
|
+
def _genome(seed=0):
|
|
18
|
+
torch.manual_seed(seed)
|
|
19
|
+
return GraphGenome(edge_index=torch.randint(0, 8, (2, 10)), num_nodes=8)
|
|
20
|
+
|
|
21
|
+
|
|
22
|
+
def _ga_result(n_gen=5):
|
|
23
|
+
cfg = GeneticAlgorithmConfig(population_size=6, n_generations=n_gen, seed=0)
|
|
24
|
+
return GeneticAlgorithmOptimizer(cfg, connectivity_fitness).optimize([_genome(i) for i in range(6)])
|
|
25
|
+
|
|
26
|
+
|
|
27
|
+
class TestGAHistory:
|
|
28
|
+
def test_history_attribute_exists(self):
|
|
29
|
+
r = _ga_result()
|
|
30
|
+
assert hasattr(r, "history")
|
|
31
|
+
|
|
32
|
+
def test_history_length_equals_n_generations(self):
|
|
33
|
+
n = 7
|
|
34
|
+
r = _ga_result(n)
|
|
35
|
+
assert len(r.history) == n
|
|
36
|
+
|
|
37
|
+
def test_history_entries_are_dicts(self):
|
|
38
|
+
r = _ga_result()
|
|
39
|
+
for entry in r.history:
|
|
40
|
+
assert isinstance(entry, dict)
|
|
41
|
+
|
|
42
|
+
def test_history_has_required_keys(self):
|
|
43
|
+
r = _ga_result()
|
|
44
|
+
for entry in r.history:
|
|
45
|
+
assert "generation" in entry
|
|
46
|
+
assert "best_fitness" in entry
|
|
47
|
+
|
|
48
|
+
def test_history_generation_index_correct(self):
|
|
49
|
+
r = _ga_result(4)
|
|
50
|
+
assert r.history[0]["generation"] == 0
|
|
51
|
+
assert r.history[3]["generation"] == 3
|
|
52
|
+
|
|
53
|
+
def test_best_fitness_unchanged(self):
|
|
54
|
+
r = _ga_result()
|
|
55
|
+
assert isinstance(r.best_fitness, float)
|
|
56
|
+
assert r.best_fitness > 0
|
|
57
|
+
|
|
58
|
+
def test_colab_exact_repro(self):
|
|
59
|
+
"""Exact snippet from the Colab bug report."""
|
|
60
|
+
config = GeneticAlgorithmConfig(population_size=10, n_generations=15, seed=42)
|
|
61
|
+
pop = [_genome(i) for i in range(10)]
|
|
62
|
+
result = GeneticAlgorithmOptimizer(config, connectivity_fitness).optimize(pop)
|
|
63
|
+
# These were the two print statements that triggered the bug:
|
|
64
|
+
_ = result.best_fitness # must not raise
|
|
65
|
+
_ = len(result.history) # must not raise (was AttributeError)
|
|
66
|
+
assert len(result.history) > 0
|
|
67
|
+
|
|
68
|
+
|
|
69
|
+
class TestGASummaryToDict:
|
|
70
|
+
def test_summary_returns_string(self):
|
|
71
|
+
r = _ga_result()
|
|
72
|
+
s = r.summary()
|
|
73
|
+
assert isinstance(s, str)
|
|
74
|
+
assert "Best fitness" in s
|
|
75
|
+
|
|
76
|
+
def test_to_dict_json_serializable(self):
|
|
77
|
+
r = _ga_result()
|
|
78
|
+
d = r.to_dict()
|
|
79
|
+
json.dumps(d)
|
|
80
|
+
|
|
81
|
+
def test_to_dict_has_expected_keys(self):
|
|
82
|
+
r = _ga_result()
|
|
83
|
+
d = r.to_dict()
|
|
84
|
+
assert "best_fitness" in d
|
|
85
|
+
assert "n_generations" in d
|
|
86
|
+
assert "fitness_history" in d
|
|
87
|
+
|
|
88
|
+
|
|
89
|
+
class TestNSGAIIHistory:
|
|
90
|
+
def _nsga_result(self, n_gen=6, single_fn=True):
|
|
91
|
+
cfg = EvolutionConfig(population_size=6, n_generations=n_gen, seed=0)
|
|
92
|
+
fn = connectivity_fitness if single_fn else [connectivity_fitness, connectivity_fitness]
|
|
93
|
+
return NSGAIIOptimizer(cfg, fn).optimize([_genome(i) for i in range(6)])
|
|
94
|
+
|
|
95
|
+
def test_history_attribute_exists(self):
|
|
96
|
+
r = self._nsga_result()
|
|
97
|
+
assert hasattr(r, "history")
|
|
98
|
+
|
|
99
|
+
def test_history_length_equals_n_generations(self):
|
|
100
|
+
n = 8
|
|
101
|
+
r = self._nsga_result(n)
|
|
102
|
+
assert len(r.history) == n
|
|
103
|
+
|
|
104
|
+
def test_history_has_generation_key(self):
|
|
105
|
+
r = self._nsga_result()
|
|
106
|
+
for entry in r.history:
|
|
107
|
+
assert "generation" in entry
|
|
108
|
+
|
|
109
|
+
def test_pareto_front_still_present(self):
|
|
110
|
+
r = self._nsga_result()
|
|
111
|
+
assert r.pareto_front is not None
|
|
112
|
+
|
|
113
|
+
def test_single_callable_accepted(self):
|
|
114
|
+
"""NSGAIIOptimizer must accept a single callable (not just a list)."""
|
|
115
|
+
cfg = EvolutionConfig(population_size=4, n_generations=3, seed=0)
|
|
116
|
+
r = NSGAIIOptimizer(cfg, connectivity_fitness).optimize([_genome(i) for i in range(4)])
|
|
117
|
+
assert len(r.history) == 3
|
|
118
|
+
|
|
119
|
+
def test_list_of_fns_still_works(self):
|
|
120
|
+
"""Passing a list of functions must still work."""
|
|
121
|
+
cfg = EvolutionConfig(population_size=4, n_generations=3, seed=0)
|
|
122
|
+
r = NSGAIIOptimizer(cfg, [connectivity_fitness, connectivity_fitness]).optimize(
|
|
123
|
+
[_genome(i) for i in range(4)]
|
|
124
|
+
)
|
|
125
|
+
assert len(r.history) == 3
|
|
@@ -10,7 +10,7 @@ Common one-liner imports::
|
|
|
10
10
|
"""
|
|
11
11
|
|
|
12
12
|
# Keep this in sync with [project].version in pyproject.toml.
|
|
13
|
-
__version__ = "1.3.
|
|
13
|
+
__version__ = "1.3.2"
|
|
14
14
|
|
|
15
15
|
# ── Core data structures ──────────────────────────────────────────────────────
|
|
16
16
|
from .core.graph import Graph, GraphBatch
|
|
@@ -6,7 +6,7 @@ from __future__ import annotations
|
|
|
6
6
|
|
|
7
7
|
import math
|
|
8
8
|
from dataclasses import dataclass, field
|
|
9
|
-
from typing import Any, Callable, Dict, List, Optional
|
|
9
|
+
from typing import Any, Callable, Dict, List, Optional, Union
|
|
10
10
|
|
|
11
11
|
import torch
|
|
12
12
|
|
|
@@ -49,14 +49,24 @@ class GeneticAlgorithmConfig:
|
|
|
49
49
|
class EvolutionResult:
|
|
50
50
|
"""Result of an evolutionary optimization run.
|
|
51
51
|
|
|
52
|
-
|
|
52
|
+
Attributes:
|
|
53
53
|
best_genome: Best genome found.
|
|
54
|
-
best_fitness: Best fitness value.
|
|
55
|
-
fitness_history: Best fitness per generation
|
|
54
|
+
best_fitness: Best fitness value (scalar).
|
|
55
|
+
fitness_history: Best fitness value per generation ``[float, ...]``.
|
|
56
56
|
diversity_history: WL uniqueness fraction per generation.
|
|
57
|
-
pareto_front: Pareto front (
|
|
57
|
+
pareto_front: Pareto front (multi-objective only; ``None`` otherwise).
|
|
58
58
|
config: Configuration used.
|
|
59
59
|
extra: Additional metadata.
|
|
60
|
+
|
|
61
|
+
Derived properties:
|
|
62
|
+
history: Per-generation list of dicts::
|
|
63
|
+
|
|
64
|
+
[{"generation": 0, "best_fitness": ..., "diversity": ...,
|
|
65
|
+
"pareto_front_size": ..., "population_size": ...}, ...]
|
|
66
|
+
|
|
67
|
+
Methods:
|
|
68
|
+
summary(): Return a human-readable string.
|
|
69
|
+
to_dict(): Return a JSON-serialisable dict.
|
|
60
70
|
"""
|
|
61
71
|
|
|
62
72
|
best_genome: Optional[GraphGenome]
|
|
@@ -67,6 +77,75 @@ class EvolutionResult:
|
|
|
67
77
|
config: Optional[Any] = None
|
|
68
78
|
extra: Dict[str, Any] = field(default_factory=dict)
|
|
69
79
|
|
|
80
|
+
@property
|
|
81
|
+
def history(self) -> List[Dict[str, Any]]:
|
|
82
|
+
"""Per-generation evolution history.
|
|
83
|
+
|
|
84
|
+
Returns a list of dicts, one entry per completed generation::
|
|
85
|
+
|
|
86
|
+
[
|
|
87
|
+
{"generation": 0, "best_fitness": 0.82, "diversity": 0.9,
|
|
88
|
+
"pareto_front_size": None, "population_size": None},
|
|
89
|
+
...
|
|
90
|
+
]
|
|
91
|
+
|
|
92
|
+
Fields present in every entry:
|
|
93
|
+
generation (int): 0-based generation index.
|
|
94
|
+
best_fitness (float or None): Best fitness seen at that generation.
|
|
95
|
+
diversity (float or None): Population diversity (WL uniqueness).
|
|
96
|
+
pareto_front_size (int or None): Pareto-front size for
|
|
97
|
+
multi-objective runs; ``None`` for single-objective.
|
|
98
|
+
population_size (int or None): Population size if stored in
|
|
99
|
+
``extra["population_sizes"]``; else ``None``.
|
|
100
|
+
"""
|
|
101
|
+
n = max(len(self.fitness_history), len(self.diversity_history))
|
|
102
|
+
# Pareto-front sizes per generation if available.
|
|
103
|
+
pf_sizes: List[Optional[int]] = self.extra.get("pareto_front_sizes", [])
|
|
104
|
+
pop_sizes: List[Optional[int]] = self.extra.get("population_sizes", [])
|
|
105
|
+
result = []
|
|
106
|
+
for i in range(n):
|
|
107
|
+
entry: Dict[str, Any] = {
|
|
108
|
+
"generation": i,
|
|
109
|
+
"best_fitness": self.fitness_history[i] if i < len(self.fitness_history) else None,
|
|
110
|
+
"diversity": self.diversity_history[i] if i < len(self.diversity_history) else None,
|
|
111
|
+
"pareto_front_size": pf_sizes[i] if i < len(pf_sizes) else None,
|
|
112
|
+
"population_size": pop_sizes[i] if i < len(pop_sizes) else None,
|
|
113
|
+
}
|
|
114
|
+
result.append(entry)
|
|
115
|
+
return result
|
|
116
|
+
|
|
117
|
+
def summary(self) -> str:
|
|
118
|
+
"""Return a human-readable summary string (also prints it)."""
|
|
119
|
+
lines = [
|
|
120
|
+
"=" * 50,
|
|
121
|
+
"TGraphX Evolutionary Optimization Result",
|
|
122
|
+
"=" * 50,
|
|
123
|
+
f"Best fitness: {self.best_fitness:.6f}",
|
|
124
|
+
f"Generations: {len(self.fitness_history)}",
|
|
125
|
+
]
|
|
126
|
+
if self.pareto_front:
|
|
127
|
+
lines.append(f"Pareto front: {len(self.pareto_front)} solutions")
|
|
128
|
+
if self.fitness_history:
|
|
129
|
+
lines.append(f"Initial best: {self.fitness_history[0]:.6f}")
|
|
130
|
+
lines.append(f"Final best: {self.fitness_history[-1]:.6f}")
|
|
131
|
+
text = "\n".join(lines)
|
|
132
|
+
print(text)
|
|
133
|
+
return text
|
|
134
|
+
|
|
135
|
+
def to_dict(self) -> Dict[str, Any]:
|
|
136
|
+
"""Return a JSON-serialisable dict (excludes non-serialisable genome)."""
|
|
137
|
+
return {
|
|
138
|
+
"best_fitness": float(self.best_fitness),
|
|
139
|
+
"n_generations": len(self.fitness_history),
|
|
140
|
+
"fitness_history": [float(f) for f in self.fitness_history],
|
|
141
|
+
"diversity_history": [float(d) for d in self.diversity_history],
|
|
142
|
+
"pareto_front_size": len(self.pareto_front) if self.pareto_front else None,
|
|
143
|
+
"extra": {
|
|
144
|
+
k: v for k, v in self.extra.items()
|
|
145
|
+
if isinstance(v, (str, int, float, bool, list, dict, type(None)))
|
|
146
|
+
},
|
|
147
|
+
}
|
|
148
|
+
|
|
70
149
|
|
|
71
150
|
def _compute_diversity(population: List[GraphGenome]) -> float:
|
|
72
151
|
"""Compute population diversity as WL uniqueness fraction."""
|
|
@@ -333,10 +412,14 @@ class NSGAIIOptimizer:
|
|
|
333
412
|
def __init__(
|
|
334
413
|
self,
|
|
335
414
|
config: EvolutionConfig,
|
|
336
|
-
fitness_fn_list: List[Callable[[GraphGenome], float]],
|
|
415
|
+
fitness_fn_list: Union[Callable[[GraphGenome], float], List[Callable[[GraphGenome], float]]],
|
|
337
416
|
) -> None:
|
|
338
417
|
self.config = config
|
|
339
|
-
|
|
418
|
+
# Accept a single callable for convenience (wraps it in a one-element list).
|
|
419
|
+
if callable(fitness_fn_list) and not isinstance(fitness_fn_list, list):
|
|
420
|
+
self.fitness_fn_list = [fitness_fn_list]
|
|
421
|
+
else:
|
|
422
|
+
self.fitness_fn_list = fitness_fn_list
|
|
340
423
|
self._generator: Optional[torch.Generator] = None
|
|
341
424
|
if config.seed is not None:
|
|
342
425
|
self._generator = torch.Generator()
|
|
@@ -358,6 +441,10 @@ class NSGAIIOptimizer:
|
|
|
358
441
|
"""
|
|
359
442
|
population = [g.clone() for g in initial_population]
|
|
360
443
|
|
|
444
|
+
fitness_history: List[float] = []
|
|
445
|
+
diversity_history: List[float] = []
|
|
446
|
+
pareto_front_sizes: List[int] = []
|
|
447
|
+
|
|
361
448
|
for gen in range(self.config.n_generations):
|
|
362
449
|
# Generate offspring
|
|
363
450
|
offspring = []
|
|
@@ -381,6 +468,13 @@ class NSGAIIOptimizer:
|
|
|
381
468
|
n_select=self.config.population_size,
|
|
382
469
|
)
|
|
383
470
|
|
|
471
|
+
# Track per-generation history.
|
|
472
|
+
gen_fitness = [fn(g) for fn in self.fitness_fn_list for g in population]
|
|
473
|
+
best_f1 = max(self.fitness_fn_list[0](g) for g in population)
|
|
474
|
+
fitness_history.append(best_f1)
|
|
475
|
+
diversity_history.append(_compute_diversity(population))
|
|
476
|
+
pareto_front_sizes.append(len(population))
|
|
477
|
+
|
|
384
478
|
if progress_callback:
|
|
385
479
|
progress_callback(gen, len(population))
|
|
386
480
|
|
|
@@ -411,8 +505,11 @@ class NSGAIIOptimizer:
|
|
|
411
505
|
return EvolutionResult(
|
|
412
506
|
best_genome=best_genome,
|
|
413
507
|
best_fitness=best_fitness,
|
|
508
|
+
fitness_history=fitness_history,
|
|
509
|
+
diversity_history=diversity_history,
|
|
414
510
|
pareto_front=pareto_front,
|
|
415
511
|
config=self.config,
|
|
512
|
+
extra={"pareto_front_sizes": pareto_front_sizes},
|
|
416
513
|
)
|
|
417
514
|
|
|
418
515
|
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: tgraphx
|
|
3
|
-
Version: 1.3.
|
|
3
|
+
Version: 1.3.2
|
|
4
4
|
Summary: Tensor-aware graph neural networks preserving spatial node feature layouts
|
|
5
5
|
Author-email: Arash Sajjadi <arash.sajjadi@usask.ca>
|
|
6
6
|
Maintainer-email: Arash Sajjadi <arash.sajjadi@usask.ca>
|
|
@@ -198,6 +198,8 @@ out.sum().backward()
|
|
|
198
198
|
A Colab tutorial walks through every workflow:
|
|
199
199
|
[](https://colab.research.google.com/drive/1agls1xtqE5WxbWthcG0HEa3Gbk3fvoCD?usp=sharing)
|
|
200
200
|
|
|
201
|
+
**Notebook gallery:** 13 scenario-driven notebooks covering Easy Mode, tensor-native image-patch graphs, sampling, knowledge graphs (including KG HPO and multimodal entity features), and graph generation are available in [docs/colab_gallery.md](docs/colab_gallery.md).
|
|
202
|
+
|
|
201
203
|
---
|
|
202
204
|
|
|
203
205
|
## Capability map
|
|
@@ -27,6 +27,7 @@ tests/test_edge_features.py
|
|
|
27
27
|
tests/test_edge_weight.py
|
|
28
28
|
tests/test_estimators_v05.py
|
|
29
29
|
tests/test_evolutionary_graph_optimization.py
|
|
30
|
+
tests/test_evolutionary_history_v132.py
|
|
30
31
|
tests/test_experiments.py
|
|
31
32
|
tests/test_explainability.py
|
|
32
33
|
tests/test_factories.py
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|