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

what is "lighting" transformation #10

Open
crazysal opened this issue Sep 14, 2021 · 1 comment
Open

what is "lighting" transformation #10

crazysal opened this issue Sep 14, 2021 · 1 comment

Comments

@crazysal
Copy link

How were the hard coded values below calculated :

db> coco.py> Line> init()

self._eig_val = np.array([0.2141788, 0.01817699, 0.00341571], dtype=np.float32)
self._eig_vec = np.array([
           [-0.58752847, -0.69563484, 0.41340352],
           [-0.5832747, 0.00994535, -0.81221408],
           [-0.56089297, 0.71832671, 0.41158938]], dtype=np.float32)

These are then used in this function :
utils>image.py> lighting_


def lighting_(data_rng, image, alphastd, eigval, eigvec):
    alpha = data_rng.normal(scale=alphastd, size=(3, ))
    image += np.dot(eigvec, eigval * alpha)


Please explain.

@crazysal
Copy link
Author

Digging deeper these are values from original coco dataset. And redundant for this paper.

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

No branches or pull requests

1 participant