Refactored RegionDetector class, such that it inherits the Detector
class