TRAIS-Lab / dattri

`dattri` is a PyTorch library for developing, benchmarking, and deploying efficient data attribution algorithms.
https://trais-lab.github.io/dattri/
MIT License
27 stars 8 forks source link

Enable `ruff` opt-in preview mode. #23

Closed xingjian-zhang closed 5 months ago

xingjian-zhang commented 5 months ago

Context

Currently, many common checks (like E231) are not enabled because ruff's opt-in preview mode is disabled.

Changes

Caveat

We may need to manually add ignored checks in pyproject.toml introduced by preview mode.

TheaperDeng commented 5 months ago

LGTM. Since this one may affect #14 and #16 (both are ready to merge before this PR). Maybe we can

  1. Merge #14 and #16
  2. Change this PR to make codes already in main branch could pass the preview rules
  3. Let other PRs that are not merged change the code by themselves.
xingjian-zhang commented 5 months ago

Sounds good to me

TheaperDeng commented 5 months ago

14 and #16 have been merged, please re-run the check and (if needed) revise this PR.

xingjian-zhang commented 5 months ago

Just fixed some new style errors. Now the pr is ready to merge.