query_utils
get_data_properties_plus_inherited_by_class_iri(kg, entity_iri)
¶
Retrieves data properties plus the inherited ones, given an entity IRI
Parameters:
Name | Type | Description | Default |
---|---|---|---|
kg | Graph | Graph object to use when querying | required |
entity_iri | str | IRI of entity to query | required |
Returns:
Name | Type | Description |
---|---|---|
List | List | contains rows of data property IRIs and their range |
Source code in exe_kg_lib/utils/query_utils.py
112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 |
|
get_method_by_task_iri(kg, namespace_prefix, namespace, task_iri)
¶
Retrieves a task's method, given a task IRI
Parameters:
Name | Type | Description | Default |
---|---|---|---|
kg | Graph | Graph object to use when querying | required |
namespace_prefix | str | namespace prefix to use when querying | required |
namespace | Namespace | namespace to use when querying | required |
task_iri | str | IRI of task to query | required |
Returns:
Type | Description |
---|---|
Optional[Entity] | Optional[Entity]: object containing found method's basic info is equal to None if method IRI wasn't found in KG |
Source code in exe_kg_lib/utils/query_utils.py
155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 |
|
get_pipeline_and_first_task_iri(kg, namespace_prefix)
¶
Retrieves the necessary information needed to start parsing a pipeline
Parameters:
Name | Type | Description | Default |
---|---|---|---|
kg | Graph | Graph object to use when querying | required |
namespace_prefix | str | namespace prefix to use when querying | required |
Returns:
Type | Description |
---|---|
Tuple[str, str, str] | Tuple[str, str, str]: contains the pipeline IRI, the input data path and the first task's IRI |
Source code in exe_kg_lib/utils/query_utils.py
130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 |
|
Last update: October 20, 2023