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

Unified naming convention #426

Closed
eldarkurtic opened this issue Oct 20, 2021 · 2 comments
Closed

Unified naming convention #426

eldarkurtic opened this issue Oct 20, 2021 · 2 comments
Assignees
Labels
enhancement New feature or request

Comments

@eldarkurtic
Copy link
Contributor

Is your feature request related to a problem? Please describe.
It might be worth considering a unified naming convention for these attributes:

        # initialize masks to all ones
        self._param_masks = [torch.ones(param.shape) for param in self._params]
        self._params_init = [None] * len(self._layers)  # type: List[Tensor]
        self._params_unmasked = [None] * len(self._layers)  # type: List[Tensor]
        self._params_grad = [None] * len(self._layers)  # type: List[Tensor]
        self._params_movement = [None] * len(self._layers)  # type: List[Tensor]

Describe the solution you'd like
Either all with self._param_* or all with self._params_*. Then we wouldn't need to check __init__ to see if an attribute starts with param or params. This would probably make these things easier to identify: #424

@eldarkurtic eldarkurtic added the enhancement New feature or request label Oct 20, 2021
@markurtz markurtz self-assigned this Nov 8, 2021
@markurtz
Copy link
Member

markurtz commented Nov 8, 2021

Hey @eldarkurtic, this is a great point that we should get updated. We'll create an internal ticket to address. If you'd like to push up a change as well feel free and we'll get it reviewed and landed.

@markurtz
Copy link
Member

Hey @eldarkurtic, we've gone through a refactor of the pruning modifiers with the 0.11 release and with that the code has changed to be more standardized. I'm going to close this out for now and feel free to reopen or open up a new one with any other suggestions!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants