servicex.func_adl package¶
Submodules¶
servicex.func_adl.func_adl_dataset module¶
- class servicex.func_adl.func_adl_dataset.FuncADLQuery(item_type: Type = typing.Any)[source]¶
Bases:
QueryStringGenerator
,EventDataset
[T
],ABC
ServiceX Dataset class that uses func_adl query syntax.
- as_qastle()[source]¶
Generate Qastle from this AST
- Returns:
Qastle representation of the target’s AST
- default_codegen: str | None = None¶
- async execute_result_async(a: AST, title: str | None = None) Any [source]¶
Required override of EventDataset
- generate_qastle(a: AST) str [source]¶
Generate the qastle from the ast of the query.
1. The top level function is already marked as being “ok” 1. If the top level function is something we have to process locally,
then we strip it off.
- Parameters:
a (ast.AST) – The complete AST of the request.
- Returns:
Qastle that should be sent to servicex
- Return type:
str
- set_tree(tree_name: str) FuncADLQuery[T] [source]¶
Set the tree name for the query. :param tree_name: Name of the tree to use for the query :type tree_name: str
- Returns:
The Dataset with the tree appended to the first call object
- class servicex.func_adl.func_adl_dataset.FuncADLQuery_ATLASr21(item_type: Type = typing.Any)[source]¶
Bases:
FuncADLQuery
- default_codegen: str | None = 'atlasr21'¶
- yaml_tag = '!FuncADL_ATLASr21'¶
- class servicex.func_adl.func_adl_dataset.FuncADLQuery_ATLASr22(item_type: Type = typing.Any)[source]¶
Bases:
FuncADLQuery
- default_codegen: str | None = 'atlasr22'¶
- yaml_tag = '!FuncADL_ATLASr22'¶
- class servicex.func_adl.func_adl_dataset.FuncADLQuery_ATLASxAOD(item_type: Type = typing.Any)[source]¶
Bases:
FuncADLQuery
- default_codegen: str | None = 'atlasxaod'¶
- yaml_tag = '!FuncADL_ATLASxAOD'¶
- class servicex.func_adl.func_adl_dataset.FuncADLQuery_CMS(item_type: Type = typing.Any)[source]¶
Bases:
FuncADLQuery
- default_codegen: str | None = 'cms'¶
- yaml_tag = '!FuncADL_CMS'¶
servicex.func_adl.func_adl_dataset_group module¶
servicex.func_adl.util module¶
- exception servicex.func_adl.util.FuncADLServerException(msg)[source]¶
Bases:
Exception
Thrown when an exception happens contacting the server
- servicex.func_adl.util.has_col_names(a: AST) bool [source]¶
Determine if any column names were specified in this request.
- Parameters:
a (ast.AST) – The complete AST of the request.
- Returns:
True if no column names were specified, False otherwise.
- Return type:
bool
- servicex.func_adl.util.has_tuple(a: AST) bool [source]¶
Determine if this query used tuples in its final result
NOTE: This can’t do depth searches in a really complex query - then you need to follow best practices.
- Parameters:
a (ast.AST) – The query
- Returns:
True if the final Select statement has tuples or not.
- Return type:
bool