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

Add QoL helpers for building 'closures' #63

Merged
merged 11 commits into from
May 5, 2024
Merged

Conversation

SimonBoothroyd
Copy link
Owner

Description

Provide a brief description of the PR's purpose here.

Status

  • Ready to go

else descent.utils.molecule.unmap_smiles(entry["smiles_b"])
),
"pred": f"{float(value):.3f} ± {float(std):.3f}",
"ref": f"{float(entry['value']):.3f}{std_ref}",
Copy link
Collaborator

@jthorton jthorton Mar 20, 2024

Choose a reason for hiding this comment

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

If entry["std"] is not None this prints the string " ± {float(entry['std']):.3f}"

@@ -631,10 +620,77 @@ def predict(
torch.nan if entry["std"] is None else entry["std"] * abs(type_scale)
)

if verbose:
std_ref = "" if entry["std"] is None else " ± {float(entry['std']):.3f}"
Copy link
Collaborator

Choose a reason for hiding this comment

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

Suggested change
std_ref = "" if entry["std"] is None else " ± {float(entry['std']):.3f}"
std_ref = "" if entry["std"] is None else f" ± {float(entry['std']):.3f}"

Copy link
Owner Author

Choose a reason for hiding this comment

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

good catch, should be fixed in the latest commit!

@SimonBoothroyd SimonBoothroyd marked this pull request as ready for review May 5, 2024 23:34
@SimonBoothroyd
Copy link
Owner Author

@jthorton i'm going to split the train helpers out into their own PR to make it a bit cleaner

@SimonBoothroyd SimonBoothroyd changed the title Add QoL helpers for training Add QoL helpers for building 'closures' May 5, 2024
@SimonBoothroyd SimonBoothroyd merged commit e5a7f1c into main May 5, 2024
1 check passed
@SimonBoothroyd SimonBoothroyd deleted the qol-additions branch May 5, 2024 23:41
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.

2 participants