Skip to content

Conversation

@flinder
Copy link
Contributor

@flinder flinder commented Dec 15, 2025

Summary: Simplified two redundant True if condition else False patterns to direct boolean expressions. The comparison already returns a boolean, so wrapping in a ternary is unnecessary.

Reviewed By: leepface

Differential Revision: D89060702

@meta-cla meta-cla bot added the CLA Signed This label is managed by the Meta Open Source bot. label Dec 15, 2025
@meta-codesync
Copy link

meta-codesync bot commented Dec 15, 2025

@flinder has exported this pull request. If you are a Meta employee, you can view the originating Diff in D89060702.

…public methods/properties in methods.py (#44)

Summary:

as title

Reviewed By: Lorenzo-Perini

Differential Revision:
D88756988

Privacy Context Container: L1334583
…ith `ValueErrors` (#48)

Summary:

Replaced 3 assert statements used for input validation with proper raise ValueError exceptions. Asserts can be disabled with Python's -O flag, making them unsuitable for production validation. This ensures validation always runs regardless of Python optimization settings.

Reviewed By: leepface

Differential Revision: D89060673
…or EARLY_STOPPING_ESTIMATION_METHOD (#49)

Summary:

Replaced a deeply nested ternary expression with a clear if/elif/else block when determining the early stopping estimation method. Added explicit type annotation before the conditional to satisfy Pyre.

Reviewed By: leepface

Differential Revision: D89060683
…n expressions (#50)

Summary:

Simplified two redundant True if condition else False patterns to direct boolean expressions. The comparison already returns a boolean, so wrapping in a ternary is unnecessary.

Reviewed By: leepface

Differential Revision: D89060702
@meta-codesync
Copy link

meta-codesync bot commented Dec 15, 2025

This pull request has been merged in 230b96d.

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

Labels

CLA Signed This label is managed by the Meta Open Source bot. fb-exported Merged meta-exported

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants