Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Diagnostic Report missing RangeCoverage for numerical columns #255

Closed
npatki opened this issue Nov 4, 2022 · 0 comments · Fixed by #256
Closed

Diagnostic Report missing RangeCoverage for numerical columns #255

npatki opened this issue Nov 4, 2022 · 0 comments · Fixed by #256
Assignees
Labels
bug Something isn't working feature:reports Related to any of the generated reports
Milestone

Comments

@npatki
Copy link
Contributor

npatki commented Nov 4, 2022

Environment Details

Please indicate the following details about the environment in which you found the bug:

  • SDMetrics version: 0.8.0
  • Python version: 3.7
  • Operating System: Linux

Error Description

According to the Diagnostic Report docs, the Coverage property is computed by applying the RangeCoverage to numerical columns and the CategoryCoverage to categorical columns.

However, when I try this on some demo data, I am not seeing the RangeCoverage property being applied.

Steps to reproduce

Python code below --

from sdv.demo import load_tabular_demo
from sdv.tabular import GaussianCopula
from sdmetrics.reports.single_table import DiagnosticReport

data = load_tabular_demo('student_placements')
data = data[['gender', 'salary', 'placed']]

metadata = {
    "fields": {
        "gender": {
            "type": "categorical"
        },
        "salary": {
            "type": "numerical", 
            "subtype": "float"
        },
        "placed": {
            "type": "categorical"
        }
    }
}

model = GaussianCopula(table_metadata=metadata)
model.fit(data)
new_data = model.sample(num_rows=200)

report = DiagnosticReport()
report.generate(data, new_data, metadata)
report.get_details('Coverage')

Notice that only the categorical columns (gender and placed) are shown in the details. The salary column is missing

image

@npatki npatki added bug Something isn't working new Label applied to new issues feature:reports Related to any of the generated reports and removed new Label applied to new issues labels Nov 4, 2022
@katxiao katxiao added this to the 0.8.1 milestone Dec 10, 2022
@katxiao katxiao self-assigned this Dec 10, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working feature:reports Related to any of the generated reports
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants