can't import kornia.augmentation.functional

1.4k Views Asked by At

I have installed kornia and imorting it like,

from kornia.color import *
import kornia.augmentation.functional as F_k
import kornia as K

but the second line is giving error

ModuleNotFoundError: No module named 'kornia.augmentation.functional'. 

Also, this is my directory structure.

directory

But I getting error

ModuleNotFoundError: No module named 'FewShot_models'

when I try to import from FewShot_models.manipulate import *. I am following a code from github and trying to implement that.

1

There are 1 best solutions below

0
old-ufo On BEST ANSWER

kornia.augmentation.functional was removed in version 0.5.4 and the most of the functions are available through kornia.augmentation.

Regarding your second question, you need to add empty file named __init__.py to FewShot_models directory. Check this answer for details about __init__.py.