Skip to content

Commit

Permalink
chore(init): make variable init a private function
Browse files Browse the repository at this point in the history
  • Loading branch information
hahnec committed Nov 4, 2021
1 parent 912e827 commit fb74f4d
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions color_matcher/mvgd_matcher.py
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ def __init__(self, *args, **kwargs):
# initialize variables
self.r, self.z, self.cov_r, self.cov_z, self.mu_r, self.mu_z, self.transfer_mat = [None]*7

def init_vars(self):
def _init_vars(self):

# reshape source and reference images
self.r, self.z = self._src.reshape([-1, self._src.shape[2]]).T, self._ref.reshape([-1, self._ref.shape[2]]).T
Expand Down Expand Up @@ -84,7 +84,7 @@ def multivar_transfer(self, src: np.ndarray = None, ref: np.ndarray = None, fun:
self.validate_color_chs()

# re-initialize variables to account for change in src and ref when passed to self.transfer()
self.init_vars()
self._init_vars()

# set solver function for transfer matrix
self._fun_call = fun if fun is FunctionType else self._fun_call
Expand Down

0 comments on commit fb74f4d

Please sign in to comment.