lcc.data_manager package¶
Submodules¶
lcc.data_manager.filter_serializer module¶
lcc.data_manager.package_reader module¶
-
class
lcc.data_manager.package_reader.
PackageReader
[source]¶ Bases:
object
Class for managing modules and its classes in the package
Attributes
MODULE_EXTENSION (iterable) Accepted extensions of module files. NAMES (dict) Keys are identifiers for path to the package where searched classes are located and base filter which all package classes needs to inherit in order to be accepted. EXCLUDE (iterable) File names (first letters of them) which will be excluded. Methods
-
EXCLUDE
= ()¶
-
MODULE_EXTENSIONS
= ('.py',)¶
-
NAMES
= {'descriptors': ('lcc/stars_processing/descriptors', <class 'lcc.stars_processing.utilities.base_descriptor.BaseDescriptor'>), 'connectors': ('lcc/db_tier/connectors', <class 'lcc.db_tier.base_query.StarsCatalogue'>), 'deciders': ('lcc/stars_processing/deciders', <class 'lcc.stars_processing.utilities.base_decider.BaseDecider'>), 'unsup_deciders': ('lcc/stars_processing/deciders/unsupervised', <class 'lcc.stars_processing.utilities.base_decider.BaseDecider'>)}¶
-
classmethod
getClasses
(name)[source]¶ Get all classes in the package which inherit base classes according to NAME attribute
Parameters: name : str
Key in NAME dictionary to package location and parent class
Returns: list
List of all classes in the package which inherit base classes according to NAME attribute
-
classmethod
getClassesDict
(package_name)[source]¶ Get dictionary of all classes in the package which inherit base classes according to NAME attribute
Parameters: package_name : str
Key in NAME dictionary to package location and parent class
Returns: dict
Dictionary of all classes in the package which inherit base classes according to NAME attribute
-
lcc.data_manager.prepare_package module¶
lcc.data_manager.status_resolver module¶
-
class
lcc.data_manager.status_resolver.
StatusResolver
(status_file_path)[source]¶ Bases:
object
This class is responsible for status files generated thru systematic searches into databases and for reading files of planned queries.
Attributes
status_header (list) Column names of status file status_queries (list) Rows of status file Methods
-
DELIMITER
= ';'¶
-
NUM_STATUS_INFO
= 4¶
-
classmethod
getUnsearchedQuery
(search_plan_file)[source]¶ Return list of queries which have not been queried yet.
Parameters: Search_plan_file : str
Path to the file of planned queries
Returns: list
List of query dictionaries
-
getWithStatus
(stat)[source]¶ Get queries with given query status
Parameters: stat : dict
Dictionary with status column name and its value
Returns: list
Returns all queries with desired status
-
static
get_with_status
(queries, stat={'passed': True})[source]¶ Return all queries with desired status
Parameters: stat : dict
Dictionary with status column name and its value
queries : list
List of query dictionaries
Returns: list
Returns all queries with desired status
-