open-metric-learning icon indicating copy to clipboard operation
open-metric-learning copied to clipboard

Make imports shortcuts

Open mimi030 opened this issue 1 year ago • 6 comments

Amendments Overview:
 This pull request introduces the following improvements:

  • Simplified import statements in the 'losses' module.
  • Simplified imports from the 'miners' module.
  • Simplified import paths for the 'models' module.
  • Simplified import statements in the 'samplers' module.
  • Simplified import examples in the 'Features Extraction' documentation.
  • Simplified imports from 'losses', 'models', 'miners', and 'samplers' within the '/oml' module.
  • Added dependencies installation info to contribution guide

Notes:
 By moving import statements into the corresponding modules' init.py files, most imports are simplified. A few import statements remain unchanged to prevent circular import issues.

Additionally, the import examples in the 'Features Extraction' documentation in Colab require permission to proceed, so they remain unchanged.

mimi030 avatar Apr 30 '24 22:04 mimi030

Hey, @mimi030 After you solve the conflicts, we can run CI/CD

AlekseySh avatar May 02 '24 20:05 AlekseySh

Also, please, double check contribution pipeline & see how to update Readme

AlekseySh avatar May 02 '24 20:05 AlekseySh

And just to make sure we are on the same page: it's not necessary to simplify the imports inside the modules. I mean, you can do it, but the final purpose if to simplify examples, so, you can only simplify imports there.

AlekseySh avatar May 02 '24 21:05 AlekseySh

And just to make sure we are on the same page: it's not necessary to simplify the imports inside the modules. I mean, you can do it, but the final purpose if to simplify examples, so, you can only simplify imports there.

So just to clarify, should I focus only on updating the import statements in the examples found under Features Extraction? I'm feeling a bit confused about the task scope now, as I had understood from our discussion here that we were looking to implement these changes more broadly.

To ensure I'm on the right track, could you please specify which specific files I should be targeting for these updates?

Thank you for your guidance!

mimi030 avatar May 10 '24 19:05 mimi030

Also, please, double check contribution pipeline & see how to update Readme

Certainly! I've previously gone through the Contributing in general and Contributing to documentation, but I'll be happy to double-check everything again to ensure everything is in order. If you have specific areas or updates you'd like me to focus on, please let me know.

mimi030 avatar May 10 '24 19:05 mimi030

from the guide:

## Contributing to documentation
* If you want to change `README.md` you should go to `docs/readme`, change the desired section and then build
  readme via `make build_readme`. *So, don't change the main readme file directly, otherwise tests will fail.*

AlekseySh avatar May 11 '24 18:05 AlekseySh

Close because of: https://github.com/OML-Team/open-metric-learning/issues/535#issuecomment-2155004071

AlekseySh avatar Jun 07 '24 14:06 AlekseySh