def METHOD_NAME(self):
    """
    Returns the base data directory taking the 'contextual'
    information into account, such as if the current user
    is inhouse.
    :returns: The base data path.
    :rtype: str
    """
    user_category = ""
    directory = ""
    if self.session_start_date:
        start_time = self.session_start_date.split(" ")[0]  # .replace('-', '')
    else:
        # PL. To avoid mixing users directory if they restart the application
        # after midnight but before 8 AM, the directory date doesn't change:
        _local_time = time.localtime()
        if _local_time[3] > 7:
            start_time = time.strftime("%Y-%m-%d")
        else:
            # substract 8 hours to current date to get yesterday's date.
            _local_time = time.gmtime((time.time() - 8 * 60 * 60))
            start_time = time.strftime("%Y-%m-%d", _local_time)
    if self.is_inhouse():
        # directory = os.path.join(self.base_directory, self.endstation_name,
        #                         self.get_user_category(), self.get_proposal(),
        #                         start_time)
        directory = os.path.join(
            self.base_directory,
            start_time,
            self.proposal_number,
            self.get_proposal_number(),
        )
    else:
        # directory = os.path.join(self.base_directory, self.get_user_category(),
        #                         self.get_proposal(), self.endstation_name,
        #                         start_time)
        logging.debug("SoleilSession self.base_directory %s" % self.base_directory)
        logging.debug("SoleilSession start_time %s" % start_time)
        logging.debug(
            "SoleilSession self.proposal_number %s" % self.proposal_number
        )
        logging.debug(
            "SoleilSession self.get_proposal_number() %s"
            % self.get_proposal_number()
        )
        directory = os.path.join(
            self.base_directory, start_time, self.get_proposal_number()
        )
    return directory