G-Cubed
Python G-Cubed 5.0.2.0 · build 1
Generation details
Source revision
4c4a95aded1b5ca5e8f9c292ad8250440cd9c18b (modified inputs)
Source fingerprint
e2c719b38e03c6b1748f10e26bc1caf1ead5674dd1beee6628a6ccf7b90fd39b
Generated (UTC)
2026-11-11T03:06:22.844261+00:00
Generator
pdoc 16.0.0, CPython 3.14.8
Generation metadata

gcubed.data.database_comparator

class DatabaseComparator(gcubed.base.Base):

A class to compare two databases and identify differences.

DatabaseComparator( model_a_configuration: gcubed.model_configuration.ModelConfiguration, model_b_configuration: gcubed.model_configuration.ModelConfiguration)

Overview

This class is designed to compare the databases from two G-Cubed models and document the differences between them.

Initialize the DatabaseComparator with two G-Cubed models.

Arguments

Get the first model configuration.

Get the second model configuration.

variables_in_a_not_b: pandas.Index

Get the variables in model a but not in model b.

:return: The variables in model a but not in model b.

variables_in_b_not_a: pandas.Index

Get the variables in model b but not in model a.

:return: The variables in model b but not in model a.

variables_with_different_values: pandas.Index

Get the variables in both models that are not close in value.

Return

The variables in both models that are not close in value.

data_a: pandas.DataFrame

Get the data for model a.

data_b: pandas.DataFrame

Get the data for model b.

def save_comparison_results(self, output_directory_path: pathlib.Path):

Save the comparison results to CSV files.

Arguments

  • output_directory: The directory to save the CSV files.