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 AlchemiscaleClient methods set_tasks and set_transformations_tasks #293

Open
dotsdl opened this issue Aug 23, 2024 · 1 comment
Open

Comments

@dotsdl
Copy link
Member

dotsdl commented Aug 23, 2024

There are users and downstream projects, such as asap-alchemy, that are more interested in ensuring that a certain number of Tasks exist per Transformation than in creating new Tasks.

This is especially the case when a user creates many iterations of AlchemicalNetworks in the same Scope that feature many Transformations in common. In this scenario, simply calling create_tasks or create_transformations_tasks on every Transformation of the submitted AlchemicalNetwork may generate more work than is necessary given existing results. A user that wants to only create new Tasks for entirely new Transformations would need to do a number of client calls to determine which Transformations have no Tasks before creating new ones.

To address this, we should create two new methods on the AlchemiscaleClient:

  • set_tasks: set the minimum number of Tasks on the given Transformation (and optionally extendsing another Task)
  • set_transformations_tasks: set the minimum number of Tasks for multiple Transformation (and optionally extendsing another Task), in a single call

These methods are functionally idempotent versions of create_tasks and create_transformations_tasks that already exist in the AlchemiscaleClient. They should take the same inputs as these existing methods, but will only create new Tasks where an insufficient number already exist.

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

No branches or pull requests

1 participant