I have this kind of problem attributeError: module 'ResponseLayer' has no attribute 'RS'. I am a beginner just started learning python from scratch. What do i need to understand here? Am i wrong coding this?
class ResponseLayer:
def RS(self,_width, _height, _step, _filter):
self.width = _width
self.height = _height
self.step = _step
self.filterr = _filter
class FastHessian:
import ResponseLayer
def buildResponseMap():
responseMap = []
w = int(img.Width / init)
h = int(img.Height / init)
s = int(init)
if (octaves >=1):
responseMap.append(RS(w, h, s, 9))
responseMap.append(RS(w, h, s, 15))
responseMap.append(RS(w, h, s, 21))
responseMap.append(RS(w, h, s, 27))
imgandoctavesare not defined, for example). Please edit your question to include enough code that we can run it. See minimal reproducible example.import ReponseLayerimplies you have a file namedResponseLayer.pysomewhere, and the module is distinct from the any class by the same name that might defined in the file. Further,RSis a method, not a class, so it's not clear what code is generating theAttributeErroror why you aren't getting aNameErroron the use ofRSyou show.