aimhubio / aim

Aim 💫 — An easy-to-use & supercharged open-source experiment tracker.
https://aimstack.io
Apache License 2.0
4.93k stars 297 forks source link

[feat] Add feature to delete full experiments #3158

Closed mauricekraus closed 2 weeks ago

mauricekraus commented 3 weeks ago

This pull request introduces the ability to delete entire experiments directly from the user interface.

Key Changes:

Delete Full Experiments:

Users can now delete entire experiments without having to manually select and delete individual runs. This resolves the issue of having empty experiments after all runs are deleted, providing a more streamlined workflow. Delete all runs of an experiment:

UI Consistency:

image

The delete functionality for experiments is currently available only on the experiment settings tab, making it consistent with the existing run detail deletion process.

How we should delete experiments from the dashboard needs further discussion (due to the space constraints)

Issues Resolved: Closes #2528 , #2803

mihran113 commented 2 weeks ago

Hey @mauricekraus! Thanks for opening the PR. the UI side looks great! But deleting the runs from BE side is a bit more complicated process as seen here: https://github.com/aimhubio/aim/blob/7c77d1c290d646238f24d81e262a85e9329544f9/aim/sdk/repo.py#L804

I guess, there will be a need to go over the experiment runs in a loop and delete them separately. It would be great if you can make those changes.

mauricekraus commented 2 weeks ago

Sure, thanks for the heads up, i totally missed the remote part as well as the rockdb stuff.

mihran113 commented 2 weeks ago

Handling the remote part is unnecessary in this case cause repo will be local for the UI anyways. (It's for handling the run deletions from CLI and SDK)

mauricekraus commented 2 weeks ago

@mihran113 this should resolve it, however, I'm still not sure about the remote thingy, at least locally this implementation gets rid of all runs in an experiment.

mihran113 commented 2 weeks ago

Hey @mauricekraus! Thank a lot for the changes. This should do the job. Regarding the remote: don't worry about it, I'll add that in the future when there'll be a need.
I'll run some tests to see if everything works fine and merge the PR. In the meanwhile can I ask you to change the destination branch to the aihmhubio:main and update the changelog like this:

## Unreleased

### Enhancements:
- Add feature to delete full experiments (mauricekraus)

And also would be great if you would address some code style issues here: https://github.com/aimhubio/aim/actions/runs/9455877092/job/26047473072