Skip to content

Fix default workload for datasets with fewer than three columns - #196

Open
ArijanaBohr wants to merge 1 commit into
google:mainfrom
ArijanaBohr:fix-default-workload-two-columns
Open

ArijanaBohr wants to merge 1 commit into
google:mainfrom
ArijanaBohr:fix-default-workload-two-columns

Conversation

@ArijanaBohr

Copy link
Copy Markdown

The default workload in supporting_cliques and compiled_workload uses all three-way marginals. For datasets with fewer than three columns, this produces an empty workload and can cause mechanisms such as AIM and SWIFT to fail.

Datasets with fewer than three columns, however, are already supported elsewhere (e.g., MST), and compiled_workload is tested with a two-column domain when an explicit workload is provided. This leaves the default workload (workload=None) as the remaining edge case for datasets with fewer than three columns.

This PR sets the default workload degree to min(3, len(domain.attributes)), preserving the existing behavior for datasets with three or more columns while using the maximum possible degree for datasets with fewer columns. The supporting_cliques docstring is updated accordingly.

Testing

  • Added regression tests for the two-column default-workload case.
  • Ran the full test suite successfully.

@google-cla

google-cla Bot commented Sep 22, 2026

Copy link
Copy Markdown

Thanks for your pull request! It looks like this may be your first contribution to a Google open source project. Before we can look at your pull request, you'll need to sign a Contributor License Agreement (CLA).

View this failed invocation of the CLA check for more information.

For the most up to date status, view the checks section at the bottom of the pull request.

@github-actions github-actions Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👋 Welcome, and thanks for opening your first PR!

We're excited to have you contribute. A few things to help you get started:

  • Join the community! Say hello on the Google Differential Privacy Slack — we'd love to hear who you are, what you're working on, and what brought you here.
  • A maintainer will review your PR shortly. If you have questions in the meantime, don't hesitate to ask here or on Slack.

Thanks for contributing to privacy-preserving synthetic data generation! 🔐

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant