def read_conf(self):
    if (not os.path.exists(self.cfg_file)):
        raise Exception('Cannot find observation configuration file - {0}'.format(self.cfg_file))
    conf_tmp = {}
    with open(self.cfg_file) as c:
        lines = c.readlines()
    for line in lines:
        if (line.startswith('#') or (line == '') or (line == '\n')):
            continue
        key = line.strip().split()[0].strip()
        val = line.strip().split()[1].strip()
        val = self.check_type(val)
        conf_tmp[key] = val
    tmp = namedtuple('CONF', conf_tmp.keys())
    self.conf = tmp(*conf_tmp.values())
def read_conf(self):
    if (not os.path.exists(self.cfg_file)):
        raise Exception('Cannot find observation configuration file - {0}'.format(self.cfg_file))
    conf_tmp = {}
    with open(self.cfg_file) as c:
        lines = c.readlines()
    for line in lines:
        if (line.startswith('#') or (line == ) or (line == '\n')):
            continue
        key = line.strip().split()[0].strip()
        val = line.strip().split()[1].strip()
        val = self.check_type(val)
        conf_tmp[key] = val
    tmp = namedtuple('CONF', conf_tmp.keys())
    self.conf = tmp(*conf_tmp.values())