sequence stringlengths 557 12.7k | docstring stringlengths 4 15.2k |
|---|---|
(module
(function_definition
(function_name_add_user) function_name_add_user
(parameters
(identifier_self) identifier_self
(identifier_username) identifier_username
(identifier_first_name) identifier_first_name
(identifier_last_name) identifier_last_name
(identifier_email) identifier_email
(identifier_role) identifier_role
(default_parameter
(identifier_password) identifier_password
(string_"") string_""
)default_parameter
(default_parameter
(identifier_hashed_password) identifier_hashed_password
(string_"") string_""
)default_parameter
)parameters
(block
(try_statement
(block
(expression_statement
(assignment
(identifier_user) identifier_user
(call
(attribute
(identifier_self) identifier_self
(identifier_user_model) identifier_user_model
)attribute
(argument_list
)argument_list
)call
)assignment
)expression_statement
(expression_statement
(assignment
(attribute
(identifier_user) identifier_user
(identifier_first_name) identifier_first_name
)attribute
(identifier_first_name) identifier_first_name
)assignment
)expression_statement
(expression_statement
(assignment
(attribute
(identifier_user) identifier_user
(identifier_last_name) identifier_last_name
)attribute
(identifier_last_name) identifier_last_name
)assignment
)expression_statement
(expression_statement
(assignment
(attribute
(identifier_user) identifier_user
(identifier_username) identifier_username
)attribute
(identifier_username) identifier_username
)assignment
)expression_statement
(expression_statement
(assignment
(attribute
(identifier_user) identifier_user
(identifier_email) identifier_email
)attribute
(identifier_email) identifier_email
)assignment
)expression_statement
(expression_statement
(assignment
(attribute
(identifier_user) identifier_user
(identifier_active) identifier_active
)attribute
(True) True
)assignment
)expression_statement
(expression_statement
(call
(attribute
(attribute
(identifier_user) identifier_user
(identifier_roles) identifier_roles
)attribute
(identifier_append) identifier_append
)attribute
(argument_list
(identifier_role) identifier_role
)argument_list
)call
)expression_statement
(if_statement
(identifier_hashed_password) identifier_hashed_password
(block
(expression_statement
(assignment
(attribute
(identifier_user) identifier_user
(identifier_password) identifier_password
)attribute
(identifier_hashed_password) identifier_hashed_password
)assignment
)expression_statement
)block
(else_clause
(block
(expression_statement
(assignment
(attribute
(identifier_user) identifier_user
(identifier_password) identifier_password
)attribute
(call
(identifier_generate_password_hash) identifier_generate_password_hash
(argument_list
(identifier_password) identifier_password
)argument_list
)call
)assignment
)expression_statement
)block
)else_clause
)if_statement
(expression_statement
(call
(attribute
(attribute
(identifier_self) identifier_self
(identifier_get_session) identifier_get_session
)attribute
(identifier_add) identifier_add
)attribute
(argument_list
(identifier_user) identifier_user
)argument_list
)call
)expression_statement
(expression_statement
(call
(attribute
(attribute
(identifier_self) identifier_self
(identifier_get_session) identifier_get_session
)attribute
(identifier_commit) identifier_commit
)attribute
(argument_list
)argument_list
)call
)expression_statement
(expression_statement
(call
(attribute
(identifier_log) identifier_log
(identifier_info) identifier_info
)attribute
(argument_list
(call
(attribute
(attribute
(identifier_c) identifier_c
(identifier_LOGMSG_INF_SEC_ADD_USER) identifier_LOGMSG_INF_SEC_ADD_USER
)attribute
(identifier_format) identifier_format
)attribute
(argument_list
(identifier_username) identifier_username
)argument_list
)call
)argument_list
)call
)expression_statement
(return_statement
(identifier_user) identifier_user
)return_statement
)block
(except_clause
(as_pattern
(identifier_Exception) identifier_Exception
(as_pattern_target
(identifier_e) identifier_e
)as_pattern_target
)as_pattern
(block
(expression_statement
(call
(attribute
(identifier_log) identifier_log
(identifier_error) identifier_error
)attribute
(argument_list
(call
(attribute
(attribute
(identifier_c) identifier_c
(identifier_LOGMSG_ERR_SEC_ADD_USER) identifier_LOGMSG_ERR_SEC_ADD_USER
)attribute
(identifier_format) identifier_format
)attribute
(argument_list
(call
(identifier_str) identifier_str
(argument_list
(identifier_e) identifier_e
)argument_list
)call
)argument_list
)call
)argument_list
)call
)expression_statement
(expression_statement
(call
(attribute
(attribute
(identifier_self) identifier_self
(identifier_get_session) identifier_get_session
)attribute
(identifier_rollback) identifier_rollback
)attribute
(argument_list
)argument_list
)call
)expression_statement
(return_statement
(False) False
)return_statement
)block
)except_clause
)try_statement
)block
)function_definition
)module | Generic function to create user |
(module
(function_definition
(function_name_get_template_vars) function_name_get_template_vars
(parameters
(identifier_self) identifier_self
(identifier_slides) identifier_slides
)parameters
(block
(try_statement
(block
(expression_statement
(assignment
(identifier_head_title) identifier_head_title
(subscript
(subscript
(identifier_slides) identifier_slides
(integer_0) integer_0
)subscript
(string_'title') string_'title'
)subscript
)assignment
)expression_statement
)block
(except_clause
(tuple
(identifier_IndexError) identifier_IndexError
(identifier_TypeError) identifier_TypeError
)tuple
(block
(expression_statement
(assignment
(identifier_head_title) identifier_head_title
(string_"Untitled Presentation") string_"Untitled Presentation"
)assignment
)expression_statement
)block
)except_clause
)try_statement
(for_statement
(pattern_list
(identifier_slide_index) identifier_slide_index
(identifier_slide_vars) identifier_slide_vars
)pattern_list
(call
(identifier_enumerate) identifier_enumerate
(argument_list
(identifier_slides) identifier_slides
)argument_list
)call
(block
(if_statement
(not_operator
(identifier_slide_vars) identifier_slide_vars
)not_operator
(block
(continue_statement
)continue_statement
)block
)if_statement
(expression_statement
(augmented_assignment
(attribute
(identifier_self) identifier_self
(identifier_num_slides) identifier_num_slides
)attribute
(integer_1) integer_1
)augmented_assignment
)expression_statement
(expression_statement
(assignment
(identifier_slide_number) identifier_slide_number
(assignment
(subscript
(identifier_slide_vars) identifier_slide_vars
(string_'number') string_'number'
)subscript
(attribute
(identifier_self) identifier_self
(identifier_num_slides) identifier_num_slides
)attribute
)assignment
)assignment
)expression_statement
(if_statement
(boolean_operator
(subscript
(identifier_slide_vars) identifier_slide_vars
(string_'level') string_'level'
)subscript
(comparison_operator
(subscript
(identifier_slide_vars) identifier_slide_vars
(string_'level') string_'level'
)subscript
(identifier_TOC_MAX_LEVEL) identifier_TOC_MAX_LEVEL
)comparison_operator
)boolean_operator
(block
(expression_statement
(call
(attribute
(identifier_self) identifier_self
(identifier_add_toc_entry) identifier_add_toc_entry
)attribute
(argument_list
(subscript
(identifier_slide_vars) identifier_slide_vars
(string_'title') string_'title'
)subscript
(subscript
(identifier_slide_vars) identifier_slide_vars
(string_'level') string_'level'
)subscript
(identifier_slide_number) identifier_slide_number
)argument_list
)call
)expression_statement
)block
(else_clause
(block
(expression_statement
(call
(attribute
(identifier_self) identifier_self
(identifier_add_toc_entry) identifier_add_toc_entry
)attribute
(argument_list
(string_u"-") string_u"-"
(integer_1) integer_1
(identifier_slide_number) identifier_slide_number
)argument_list
)call
)expression_statement
)block
)else_clause
)if_statement
)block
)for_statement
(return_statement
(dictionary
(pair
(string_'head_title') string_'head_title'
(identifier_head_title) identifier_head_title
)pair
(pair
(string_'num_slides') string_'num_slides'
(call
(identifier_str) identifier_str
(argument_list
(attribute
(identifier_self) identifier_self
(identifier_num_slides) identifier_num_slides
)attribute
)argument_list
)call
)pair
(pair
(string_'slides') string_'slides'
(identifier_slides) identifier_slides
)pair
(pair
(string_'toc') string_'toc'
(attribute
(identifier_self) identifier_self
(identifier_toc) identifier_toc
)attribute
)pair
(pair
(string_'embed') string_'embed'
(attribute
(identifier_self) identifier_self
(identifier_embed) identifier_embed
)attribute
)pair
(pair
(string_'css') string_'css'
(call
(attribute
(identifier_self) identifier_self
(identifier_get_css) identifier_get_css
)attribute
(argument_list
)argument_list
)call
)pair
(pair
(string_'js') string_'js'
(call
(attribute
(identifier_self) identifier_self
(identifier_get_js) identifier_get_js
)attribute
(argument_list
)argument_list
)call
)pair
(pair
(string_'user_css') string_'user_css'
(attribute
(identifier_self) identifier_self
(identifier_user_css) identifier_user_css
)attribute
)pair
(pair
(string_'user_js') string_'user_js'
(attribute
(identifier_self) identifier_self
(identifier_user_js) identifier_user_js
)attribute
)pair
(pair
(string_'math_output') string_'math_output'
(attribute
(identifier_self) identifier_self
(identifier_math_output) identifier_math_output
)attribute
)pair
)dictionary
)return_statement
)block
)function_definition
)module | Computes template vars from slides html source code. |
(module
(function_definition
(function_name_delete_lbaas_port) function_name_delete_lbaas_port
(parameters
(identifier_self) identifier_self
(identifier_lb_id) identifier_lb_id
)parameters
(block
(expression_statement
(assignment
(identifier_lb_id) identifier_lb_id
(call
(attribute
(identifier_lb_id) identifier_lb_id
(identifier_replace) identifier_replace
)attribute
(argument_list
(string_'-') string_'-'
(string_'') string_''
)argument_list
)call
)assignment
)expression_statement
(expression_statement
(assignment
(identifier_req) identifier_req
(call
(identifier_dict) identifier_dict
(argument_list
(keyword_argument
(identifier_instance_id) identifier_instance_id
(identifier_lb_id) identifier_lb_id
)keyword_argument
)argument_list
)call
)assignment
)expression_statement
(expression_statement
(assignment
(identifier_instances) identifier_instances
(call
(attribute
(identifier_self) identifier_self
(identifier_get_vms_for_this_req) identifier_get_vms_for_this_req
)attribute
(argument_list
(dictionary_splat
(identifier_req) identifier_req
)dictionary_splat
)argument_list
)call
)assignment
)expression_statement
(for_statement
(identifier_vm) identifier_vm
(identifier_instances) identifier_instances
(block
(expression_statement
(call
(attribute
(identifier_LOG) identifier_LOG
(identifier_info) identifier_info
)attribute
(argument_list
(binary_operator
(string_"deleting lbaas vm %s ") string_"deleting lbaas vm %s "
(attribute
(identifier_vm) identifier_vm
(identifier_name) identifier_name
)attribute
)binary_operator
)argument_list
)call
)expression_statement
(expression_statement
(call
(attribute
(identifier_self) identifier_self
(identifier_delete_vm_function) identifier_delete_vm_function
)attribute
(argument_list
(attribute
(identifier_vm) identifier_vm
(identifier_port_id) identifier_port_id
)attribute
(identifier_vm) identifier_vm
)argument_list
)call
)expression_statement
)block
)for_statement
)block
)function_definition
)module | send vm down event and delete db.
:param lb_id: vip id for v1 and lbaas_id for v2 |
(module
(function_definition
(function_name_send_registered_email) function_name_send_registered_email
(parameters
(identifier_self) identifier_self
(identifier_user) identifier_user
(identifier_user_email) identifier_user_email
(identifier_request_email_confirmation) identifier_request_email_confirmation
)parameters
(block
(if_statement
(not_operator
(attribute
(attribute
(identifier_self) identifier_self
(identifier_user_manager) identifier_user_manager
)attribute
(identifier_USER_ENABLE_EMAIL) identifier_USER_ENABLE_EMAIL
)attribute
)not_operator
(block
(return_statement
)return_statement
)block
)if_statement
(if_statement
(not_operator
(attribute
(attribute
(identifier_self) identifier_self
(identifier_user_manager) identifier_user_manager
)attribute
(identifier_USER_SEND_REGISTERED_EMAIL) identifier_USER_SEND_REGISTERED_EMAIL
)attribute
)not_operator
(block
(return_statement
)return_statement
)block
)if_statement
(expression_statement
(assignment
(identifier_email) identifier_email
(conditional_expression
(attribute
(identifier_user_email) identifier_user_email
(identifier_email) identifier_email
)attribute
(identifier_user_email) identifier_user_email
(attribute
(identifier_user) identifier_user
(identifier_email) identifier_email
)attribute
)conditional_expression
)assignment
)expression_statement
(if_statement
(identifier_request_email_confirmation) identifier_request_email_confirmation
(block
(expression_statement
(assignment
(identifier_token) identifier_token
(call
(attribute
(attribute
(identifier_self) identifier_self
(identifier_user_manager) identifier_user_manager
)attribute
(identifier_generate_token) identifier_generate_token
)attribute
(argument_list
(conditional_expression
(attribute
(identifier_user_email) identifier_user_email
(identifier_id) identifier_id
)attribute
(identifier_user_email) identifier_user_email
(attribute
(identifier_user) identifier_user
(identifier_id) identifier_id
)attribute
)conditional_expression
)argument_list
)call
)assignment
)expression_statement
(expression_statement
(assignment
(identifier_confirm_email_link) identifier_confirm_email_link
(call
(identifier_url_for) identifier_url_for
(argument_list
(string_'user.confirm_email') string_'user.confirm_email'
(keyword_argument
(identifier_token) identifier_token
(identifier_token) identifier_token
)keyword_argument
(keyword_argument
(identifier__external) identifier__external
(True) True
)keyword_argument
)argument_list
)call
)assignment
)expression_statement
)block
(else_clause
(block
(expression_statement
(assignment
(identifier_confirm_email_link) identifier_confirm_email_link
(None) None
)assignment
)expression_statement
)block
)else_clause
)if_statement
(expression_statement
(call
(attribute
(identifier_self) identifier_self
(identifier__render_and_send_email) identifier__render_and_send_email
)attribute
(argument_list
(identifier_email) identifier_email
(identifier_user) identifier_user
(attribute
(attribute
(identifier_self) identifier_self
(identifier_user_manager) identifier_user_manager
)attribute
(identifier_USER_REGISTERED_EMAIL_TEMPLATE) identifier_USER_REGISTERED_EMAIL_TEMPLATE
)attribute
(keyword_argument
(identifier_confirm_email_link) identifier_confirm_email_link
(identifier_confirm_email_link) identifier_confirm_email_link
)keyword_argument
)argument_list
)call
)expression_statement
)block
)function_definition
)module | Send the 'user has registered' notification email. |
(module
(function_definition
(function_name__prep_cnv_file) function_name__prep_cnv_file
(parameters
(identifier_in_file) identifier_in_file
(identifier_work_dir) identifier_work_dir
(identifier_somatic_info) identifier_somatic_info
)parameters
(block
(expression_statement
(assignment
(identifier_out_file) identifier_out_file
(call
(attribute
(attribute
(identifier_os) identifier_os
(identifier_path) identifier_path
)attribute
(identifier_join) identifier_join
)attribute
(argument_list
(identifier_work_dir) identifier_work_dir
(binary_operator
(string_"%s-prep%s") string_"%s-prep%s"
(call
(attribute
(identifier_utils) identifier_utils
(identifier_splitext_plus) identifier_splitext_plus
)attribute
(argument_list
(call
(attribute
(attribute
(identifier_os) identifier_os
(identifier_path) identifier_path
)attribute
(identifier_basename) identifier_basename
)attribute
(argument_list
(identifier_in_file) identifier_in_file
)argument_list
)call
)argument_list
)call
)binary_operator
)argument_list
)call
)assignment
)expression_statement
(if_statement
(not_operator
(call
(attribute
(identifier_utils) identifier_utils
(identifier_file_uptodate) identifier_file_uptodate
)attribute
(argument_list
(identifier_out_file) identifier_out_file
(identifier_in_file) identifier_in_file
)argument_list
)call
)not_operator
(block
(with_statement
(with_clause
(with_item
(as_pattern
(call
(identifier_file_transaction) identifier_file_transaction
(argument_list
(attribute
(identifier_somatic_info) identifier_somatic_info
(identifier_tumor_data) identifier_tumor_data
)attribute
(identifier_out_file) identifier_out_file
)argument_list
)call
(as_pattern_target
(identifier_tx_out_file) identifier_tx_out_file
)as_pattern_target
)as_pattern
)with_item
)with_clause
(block
(with_statement
(with_clause
(with_item
(as_pattern
(call
(identifier_open) identifier_open
(argument_list
(identifier_in_file) identifier_in_file
)argument_list
)call
(as_pattern_target
(identifier_in_handle) identifier_in_handle
)as_pattern_target
)as_pattern
)with_item
)with_clause
(block
(with_statement
(with_clause
(with_item
(as_pattern
(call
(identifier_open) identifier_open
(argument_list
(identifier_tx_out_file) identifier_tx_out_file
(string_"w") string_"w"
)argument_list
)call
(as_pattern_target
(identifier_out_handle) identifier_out_handle
)as_pattern_target
)as_pattern
)with_item
)with_clause
(block
(expression_statement
(call
(attribute
(identifier_out_handle) identifier_out_handle
(identifier_write) identifier_write
)attribute
(argument_list
(call
(attribute
(identifier_in_handle) identifier_in_handle
(identifier_readline) identifier_readline
)attribute
(argument_list
)argument_list
)call
)argument_list
)call
)expression_statement
(for_statement
(identifier_line) identifier_line
(identifier_in_handle) identifier_in_handle
(block
(expression_statement
(assignment
(identifier_parts) identifier_parts
(call
(attribute
(identifier_line) identifier_line
(identifier_split) identifier_split
)attribute
(argument_list
(string_"\t") string_"\t"
)argument_list
)call
)assignment
)expression_statement
(expression_statement
(assignment
(subscript
(identifier_parts) identifier_parts
(integer_1) integer_1
)subscript
(call
(identifier__phylowgs_compatible_chroms) identifier__phylowgs_compatible_chroms
(argument_list
(subscript
(identifier_parts) identifier_parts
(integer_1) integer_1
)subscript
)argument_list
)call
)assignment
)expression_statement
(expression_statement
(call
(attribute
(identifier_out_handle) identifier_out_handle
(identifier_write) identifier_write
)attribute
(argument_list
(call
(attribute
(string_"\t") string_"\t"
(identifier_join) identifier_join
)attribute
(argument_list
(identifier_parts) identifier_parts
)argument_list
)call
)argument_list
)call
)expression_statement
)block
)for_statement
)block
)with_statement
)block
)with_statement
)block
)with_statement
)block
)if_statement
(return_statement
(identifier_out_file) identifier_out_file
)return_statement
)block
)function_definition
)module | Prepare Battenberg CNV file for ingest by PhyloWGS.
The PhyloWGS preparation script does not handle 'chr' prefixed chromosomes (hg19 style)
correctly. This converts them over to GRCh37 (no 'chr') style to match preparation
work in _prep_vrn_file. |
(module
(function_definition
(function_name_get_sorted_attachments) function_name_get_sorted_attachments
(parameters
(identifier_self) identifier_self
)parameters
(block
(expression_statement
(assignment
(identifier_inf) identifier_inf
(call
(identifier_float) identifier_float
(argument_list
(string_"inf") string_"inf"
)argument_list
)call
)assignment
)expression_statement
(expression_statement
(assignment
(identifier_order) identifier_order
(call
(attribute
(identifier_self) identifier_self
(identifier_get_attachments_order) identifier_get_attachments_order
)attribute
(argument_list
)argument_list
)call
)assignment
)expression_statement
(expression_statement
(assignment
(identifier_attachments) identifier_attachments
(call
(attribute
(identifier_self) identifier_self
(identifier_get_attachments) identifier_get_attachments
)attribute
(argument_list
)argument_list
)call
)assignment
)expression_statement
(function_definition
(function_name_att_cmp) function_name_att_cmp
(parameters
(identifier_att1) identifier_att1
(identifier_att2) identifier_att2
)parameters
(block
(expression_statement
(assignment
(identifier__n1) identifier__n1
(call
(attribute
(identifier_att1) identifier_att1
(identifier_get) identifier_get
)attribute
(argument_list
(string_'UID') string_'UID'
)argument_list
)call
)assignment
)expression_statement
(expression_statement
(assignment
(identifier__n2) identifier__n2
(call
(attribute
(identifier_att2) identifier_att2
(identifier_get) identifier_get
)attribute
(argument_list
(string_'UID') string_'UID'
)argument_list
)call
)assignment
)expression_statement
(expression_statement
(assignment
(identifier__i1) identifier__i1
(boolean_operator
(boolean_operator
(comparison_operator
(identifier__n1) identifier__n1
(identifier_order) identifier_order
)comparison_operator
(binary_operator
(call
(attribute
(identifier_order) identifier_order
(identifier_index) identifier_index
)attribute
(argument_list
(identifier__n1) identifier__n1
)argument_list
)call
(integer_1) integer_1
)binary_operator
)boolean_operator
(identifier_inf) identifier_inf
)boolean_operator
)assignment
)expression_statement
(expression_statement
(assignment
(identifier__i2) identifier__i2
(boolean_operator
(boolean_operator
(comparison_operator
(identifier__n2) identifier__n2
(identifier_order) identifier_order
)comparison_operator
(binary_operator
(call
(attribute
(identifier_order) identifier_order
(identifier_index) identifier_index
)attribute
(argument_list
(identifier__n2) identifier__n2
)argument_list
)call
(integer_1) integer_1
)binary_operator
)boolean_operator
(identifier_inf) identifier_inf
)boolean_operator
)assignment
)expression_statement
(return_statement
(call
(identifier_cmp) identifier_cmp
(argument_list
(identifier__i1) identifier__i1
(identifier__i2) identifier__i2
)argument_list
)call
)return_statement
)block
)function_definition
(expression_statement
(assignment
(identifier_sorted_attachments) identifier_sorted_attachments
(call
(identifier_sorted) identifier_sorted
(argument_list
(identifier_attachments) identifier_attachments
(keyword_argument
(identifier_cmp) identifier_cmp
(identifier_att_cmp) identifier_att_cmp
)keyword_argument
)argument_list
)call
)assignment
)expression_statement
(return_statement
(identifier_sorted_attachments) identifier_sorted_attachments
)return_statement
)block
)function_definition
)module | Returns a sorted list of analysis info dictionaries |
(module
(function_definition
(function_name_is_native_xmon_op) function_name_is_native_xmon_op
(parameters
(typed_parameter
(identifier_op) identifier_op
(type
(attribute
(identifier_ops) identifier_ops
(identifier_Operation) identifier_Operation
)attribute
)type
)typed_parameter
)parameters
(type
(identifier_bool) identifier_bool
)type
(block
(return_statement
(parenthesized_expression
(boolean_operator
(call
(identifier_isinstance) identifier_isinstance
(argument_list
(identifier_op) identifier_op
(attribute
(identifier_ops) identifier_ops
(identifier_GateOperation) identifier_GateOperation
)attribute
)argument_list
)call
(call
(identifier_is_native_xmon_gate) identifier_is_native_xmon_gate
(argument_list
(attribute
(identifier_op) identifier_op
(identifier_gate) identifier_gate
)attribute
)argument_list
)call
)boolean_operator
)parenthesized_expression
)return_statement
)block
)function_definition
)module | Check if the gate corresponding to an operation is a native xmon gate.
Args:
op: Input operation.
Returns:
True if the operation is native to the xmon, false otherwise. |
(module
(function_definition
(function_name_convert_unicode_2_utf8) function_name_convert_unicode_2_utf8
(parameters
(identifier_input) identifier_input
)parameters
(block
(if_statement
(call
(identifier_isinstance) identifier_isinstance
(argument_list
(identifier_input) identifier_input
(identifier_dict) identifier_dict
)argument_list
)call
(block
(try_statement
(block
(return_statement
(call
(identifier_dict) identifier_dict
(generator_expression
(tuple
(call
(identifier_convert_unicode_2_utf8) identifier_convert_unicode_2_utf8
(argument_list
(identifier_key) identifier_key
)argument_list
)call
(call
(identifier_convert_unicode_2_utf8) identifier_convert_unicode_2_utf8
(argument_list
(identifier_value) identifier_value
)argument_list
)call
)tuple
(for_in_clause
(pattern_list
(identifier_key) identifier_key
(identifier_value) identifier_value
)pattern_list
(call
(attribute
(identifier_input) identifier_input
(identifier_iteritems) identifier_iteritems
)attribute
(argument_list
)argument_list
)call
)for_in_clause
)generator_expression
)call
)return_statement
)block
(except_clause
(identifier_AttributeError) identifier_AttributeError
(block
(return_statement
(call
(identifier_eval) identifier_eval
(argument_list
)argument_list
)call
)return_statement
)block
)except_clause
)try_statement
)block
(elif_clause
(call
(identifier_isinstance) identifier_isinstance
(argument_list
(identifier_input) identifier_input
(identifier_list) identifier_list
)argument_list
)call
(block
(return_statement
(list_comprehension
(call
(identifier_convert_unicode_2_utf8) identifier_convert_unicode_2_utf8
(argument_list
(identifier_element) identifier_element
)argument_list
)call
(for_in_clause
(identifier_element) identifier_element
(identifier_input) identifier_input
)for_in_clause
)list_comprehension
)return_statement
)block
)elif_clause
(elif_clause
(call
(identifier_isinstance) identifier_isinstance
(argument_list
(identifier_input) identifier_input
(identifier_str) identifier_str
)argument_list
)call
(block
(return_statement
(identifier_input) identifier_input
)return_statement
)block
)elif_clause
(else_clause
(block
(try_statement
(block
(if_statement
(call
(identifier_eval) identifier_eval
(argument_list
)argument_list
)call
(block
(return_statement
(call
(attribute
(identifier_input) identifier_input
(identifier_encode) identifier_encode
)attribute
(argument_list
(string_'utf-8') string_'utf-8'
)argument_list
)call
)return_statement
)block
)if_statement
)block
(except_clause
(identifier_NameError) identifier_NameError
(block
(pass_statement
)pass_statement
)block
)except_clause
)try_statement
(return_statement
(identifier_input) identifier_input
)return_statement
)block
)else_clause
)if_statement
)block
)function_definition
)module | Return a copy of `input` with every str component encoded from unicode to
utf-8. |
(module
(function_definition
(function_name_RaiseIfLastError) function_name_RaiseIfLastError
(parameters
(identifier_result) identifier_result
(default_parameter
(identifier_func) identifier_func
(None) None
)default_parameter
(default_parameter
(identifier_arguments) identifier_arguments
(tuple
)tuple
)default_parameter
)parameters
(block
(expression_statement
(assignment
(identifier_code) identifier_code
(call
(identifier_GetLastError) identifier_GetLastError
(argument_list
)argument_list
)call
)assignment
)expression_statement
(if_statement
(comparison_operator
(identifier_code) identifier_code
(identifier_ERROR_SUCCESS) identifier_ERROR_SUCCESS
)comparison_operator
(block
(raise_statement
(call
(attribute
(identifier_ctypes) identifier_ctypes
(identifier_WinError) identifier_WinError
)attribute
(argument_list
(identifier_code) identifier_code
)argument_list
)call
)raise_statement
)block
)if_statement
(return_statement
(identifier_result) identifier_result
)return_statement
)block
)function_definition
)module | Error checking for Win32 API calls with no error-specific return value.
Regardless of the return value, the function calls GetLastError(). If the
code is not C{ERROR_SUCCESS} then a C{WindowsError} exception is raised.
For this to work, the user MUST call SetLastError(ERROR_SUCCESS) prior to
calling the API. Otherwise an exception may be raised even on success,
since most API calls don't clear the error status code. |
(module
(function_definition
(function_name_install) function_name_install
(parameters
)parameters
(block
(expression_statement
(assignment
(identifier_tmp_weboob_dir) identifier_tmp_weboob_dir
(string_'/tmp/weboob') string_'/tmp/weboob'
)assignment
)expression_statement
(while_statement
(parenthesized_expression
(call
(attribute
(attribute
(identifier_os) identifier_os
(identifier_path) identifier_path
)attribute
(identifier_exists) identifier_exists
)attribute
(argument_list
(identifier_tmp_weboob_dir) identifier_tmp_weboob_dir
)argument_list
)call
)parenthesized_expression
(block
(expression_statement
(augmented_assignment
(identifier_tmp_weboob_dir) identifier_tmp_weboob_dir
(string_'1') string_'1'
)augmented_assignment
)expression_statement
)block
)while_statement
(print_statement
(call
(attribute
(string_'Fetching sources in temporary dir {}') string_'Fetching sources in temporary dir {}'
(identifier_format) identifier_format
)attribute
(argument_list
(identifier_tmp_weboob_dir) identifier_tmp_weboob_dir
)argument_list
)call
)print_statement
(expression_statement
(assignment
(identifier_result) identifier_result
(call
(identifier_cmd_exec) identifier_cmd_exec
(argument_list
(call
(attribute
(string_'git clone {} {}') string_'git clone {} {}'
(identifier_format) identifier_format
)attribute
(argument_list
(identifier_WEBOOB_REPO) identifier_WEBOOB_REPO
(identifier_tmp_weboob_dir) identifier_tmp_weboob_dir
)argument_list
)call
)argument_list
)call
)assignment
)expression_statement
(if_statement
(parenthesized_expression
(subscript
(identifier_result) identifier_result
(string_'error') string_'error'
)subscript
)parenthesized_expression
(block
(print_statement
(subscript
(identifier_result) identifier_result
(string_'stderr') string_'stderr'
)subscript
)print_statement
(print_statement
(string_'Weboob installation failed: could not clone repository') string_'Weboob installation failed: could not clone repository'
)print_statement
(expression_statement
(call
(identifier_exit) identifier_exit
(argument_list
)argument_list
)call
)expression_statement
)block
)if_statement
(print_statement
(string_'Sources fetched, will now process to installation') string_'Sources fetched, will now process to installation'
)print_statement
(expression_statement
(assignment
(identifier_result) identifier_result
(call
(identifier_cmd_exec) identifier_cmd_exec
(argument_list
(call
(attribute
(string_'cd {} && ./setup.py install') string_'cd {} && ./setup.py install'
(identifier_format) identifier_format
)attribute
(argument_list
(identifier_tmp_weboob_dir) identifier_tmp_weboob_dir
)argument_list
)call
)argument_list
)call
)assignment
)expression_statement
(expression_statement
(call
(attribute
(identifier_shutil) identifier_shutil
(identifier_rmtree) identifier_rmtree
)attribute
(argument_list
(identifier_tmp_weboob_dir) identifier_tmp_weboob_dir
)argument_list
)call
)expression_statement
(if_statement
(parenthesized_expression
(subscript
(identifier_result) identifier_result
(string_'error') string_'error'
)subscript
)parenthesized_expression
(block
(print_statement
(subscript
(identifier_result) identifier_result
(string_'stderr') string_'stderr'
)subscript
)print_statement
(print_statement
(string_'Weboob installation failed: setup failed') string_'Weboob installation failed: setup failed'
)print_statement
(expression_statement
(call
(identifier_exit) identifier_exit
(argument_list
)argument_list
)call
)expression_statement
)block
)if_statement
(print_statement
(subscript
(identifier_result) identifier_result
(string_'stdout') string_'stdout'
)subscript
)print_statement
(expression_statement
(assignment
(identifier_weboob_version) identifier_weboob_version
(call
(identifier_get_weboob_version) identifier_get_weboob_version
(argument_list
)argument_list
)call
)assignment
)expression_statement
(if_statement
(parenthesized_expression
(not_operator
(identifier_weboob_version) identifier_weboob_version
)not_operator
)parenthesized_expression
(block
(print_statement
(string_'Weboob installation failed: version not detected') string_'Weboob installation failed: version not detected'
)print_statement
(expression_statement
(call
(identifier_exit) identifier_exit
(argument_list
)argument_list
)call
)expression_statement
)block
)if_statement
(print_statement
(call
(attribute
(string_'Weboob (version: {}) installation succeeded') string_'Weboob (version: {}) installation succeeded'
(identifier_format) identifier_format
)attribute
(argument_list
(identifier_weboob_version) identifier_weboob_version
)argument_list
)call
)print_statement
(expression_statement
(call
(identifier_update) identifier_update
(argument_list
)argument_list
)call
)expression_statement
)block
)function_definition
)module | Install weboob system-wide |
(module
(function_definition
(function_name_to_dict) function_name_to_dict
(parameters
(identifier_self) identifier_self
)parameters
(block
(return_statement
(dictionary
(pair
(string_"gates") string_"gates"
(list_comprehension
(call
(attribute
(identifier_km) identifier_km
(identifier_to_dict) identifier_to_dict
)attribute
(argument_list
)argument_list
)call
(for_in_clause
(identifier_km) identifier_km
(attribute
(identifier_self) identifier_self
(identifier_gates) identifier_gates
)attribute
)for_in_clause
)list_comprehension
)pair
(pair
(string_"assignment_probs") string_"assignment_probs"
(dictionary_comprehension
(pair
(call
(identifier_str) identifier_str
(argument_list
(identifier_qid) identifier_qid
)argument_list
)call
(call
(attribute
(identifier_a) identifier_a
(identifier_tolist) identifier_tolist
)attribute
(argument_list
)argument_list
)call
)pair
(for_in_clause
(pattern_list
(identifier_qid) identifier_qid
(identifier_a) identifier_a
)pattern_list
(call
(attribute
(attribute
(identifier_self) identifier_self
(identifier_assignment_probs) identifier_assignment_probs
)attribute
(identifier_items) identifier_items
)attribute
(argument_list
)argument_list
)call
)for_in_clause
)dictionary_comprehension
)pair
)dictionary
)return_statement
)block
)function_definition
)module | Create a JSON serializable representation of the noise model.
For example::
{
"gates": [
# list of embedded dictionary representations of KrausModels here [...]
]
"assignment_probs": {
"0": [[.8, .1],
[.2, .9]],
"1": [[.9, .4],
[.1, .6]],
}
}
:return: A dictionary representation of self.
:rtype: Dict[str,Any] |
(module
(function_definition
(function_name_get) function_name_get
(parameters
(identifier_s) identifier_s
(default_parameter
(identifier_delimiter) identifier_delimiter
(string_'') string_''
)default_parameter
(default_parameter
(identifier_format) identifier_format
(string_"diacritical") string_"diacritical"
)default_parameter
)parameters
(block
(return_statement
(call
(attribute
(identifier_delimiter) identifier_delimiter
(identifier_join) identifier_join
)attribute
(argument_list
(call
(identifier__pinyin_generator) identifier__pinyin_generator
(argument_list
(call
(identifier_u) identifier_u
(argument_list
(identifier_s) identifier_s
)argument_list
)call
(keyword_argument
(identifier_format) identifier_format
(identifier_format) identifier_format
)keyword_argument
)argument_list
)call
)argument_list
)call
)return_statement
)block
)function_definition
)module | Return pinyin of string, the string must be unicode |
(module
(function_definition
(function_name_withNamedValues) function_name_withNamedValues
(parameters
(identifier_cls) identifier_cls
(dictionary_splat_pattern
(identifier_values) identifier_values
)dictionary_splat_pattern
)parameters
(block
(expression_statement
(assignment
(identifier_enums) identifier_enums
(call
(identifier_set) identifier_set
(argument_list
(call
(attribute
(attribute
(identifier_cls) identifier_cls
(identifier_namedValues) identifier_namedValues
)attribute
(identifier_items) identifier_items
)attribute
(argument_list
)argument_list
)call
)argument_list
)call
)assignment
)expression_statement
(expression_statement
(call
(attribute
(identifier_enums) identifier_enums
(identifier_update) identifier_update
)attribute
(argument_list
(call
(attribute
(identifier_values) identifier_values
(identifier_items) identifier_items
)attribute
(argument_list
)argument_list
)call
)argument_list
)call
)expression_statement
(class_definition
(identifier_X) identifier_X
(argument_list
(identifier_cls) identifier_cls
)argument_list
(block
(expression_statement
(assignment
(identifier_namedValues) identifier_namedValues
(call
(attribute
(identifier_namedval) identifier_namedval
(identifier_NamedValues) identifier_NamedValues
)attribute
(argument_list
(list_splat
(identifier_enums) identifier_enums
)list_splat
)argument_list
)call
)assignment
)expression_statement
(expression_statement
(assignment
(identifier_subtypeSpec) identifier_subtypeSpec
(binary_operator
(attribute
(identifier_cls) identifier_cls
(identifier_subtypeSpec) identifier_subtypeSpec
)attribute
(call
(attribute
(identifier_constraint) identifier_constraint
(identifier_SingleValueConstraint) identifier_SingleValueConstraint
)attribute
(argument_list
(list_splat
(call
(attribute
(identifier_values) identifier_values
(identifier_values) identifier_values
)attribute
(argument_list
)argument_list
)call
)list_splat
)argument_list
)call
)binary_operator
)assignment
)expression_statement
)block
)class_definition
(expression_statement
(assignment
(attribute
(identifier_X) identifier_X
(identifier___name__) identifier___name__
)attribute
(attribute
(identifier_cls) identifier_cls
(identifier___name__) identifier___name__
)attribute
)assignment
)expression_statement
(return_statement
(identifier_X) identifier_X
)return_statement
)block
)function_definition
)module | Create a subclass with discreet named values constraint.
Reduce fully duplicate enumerations along the way. |
(module
(function_definition
(function_name_receive_data_chunk) function_name_receive_data_chunk
(parameters
(identifier_self) identifier_self
(identifier_raw_data) identifier_raw_data
(identifier_start) identifier_start
)parameters
(block
(expression_statement
(call
(attribute
(attribute
(identifier_self) identifier_self
(identifier_file) identifier_file
)attribute
(identifier_write) identifier_write
)attribute
(argument_list
(identifier_raw_data) identifier_raw_data
)argument_list
)call
)expression_statement
(expression_statement
(call
(attribute
(identifier_eventlet) identifier_eventlet
(identifier_sleep) identifier_sleep
)attribute
(argument_list
(integer_0) integer_0
)argument_list
)call
)expression_statement
)block
)function_definition
)module | Over-ridden method to circumvent the worker timeouts on large uploads. |
(module
(function_definition
(function_name_get_app_settings_from_arguments) function_name_get_app_settings_from_arguments
(parameters
(identifier_args) identifier_args
)parameters
(block
(expression_statement
(assignment
(identifier_config_filepath) identifier_config_filepath
(call
(attribute
(attribute
(identifier_os) identifier_os
(identifier_path) identifier_path
)attribute
(identifier_abspath) identifier_abspath
)attribute
(argument_list
(attribute
(identifier_args) identifier_args
(identifier_config_uri) identifier_config_uri
)attribute
)argument_list
)call
)assignment
)expression_statement
(return_statement
(call
(identifier_get_appsettings) identifier_get_appsettings
(argument_list
(identifier_config_filepath) identifier_config_filepath
(keyword_argument
(identifier_name) identifier_name
(attribute
(identifier_args) identifier_args
(identifier_config_name) identifier_config_name
)attribute
)keyword_argument
)argument_list
)call
)return_statement
)block
)function_definition
)module | Parse ``argparse`` style arguments into app settings.
Given an ``argparse`` set of arguments as ``args``
parse the arguments to return the application settings.
This assumes the parser was created using ``create_parser``. |
(module
(function_definition
(function_name_get_context_from_gdoc) function_name_get_context_from_gdoc
(parameters
(identifier_self) identifier_self
)parameters
(block
(try_statement
(block
(expression_statement
(assignment
(identifier_start) identifier_start
(call
(identifier_int) identifier_int
(argument_list
(call
(attribute
(identifier_time) identifier_time
(identifier_time) identifier_time
)attribute
(argument_list
)argument_list
)call
)argument_list
)call
)assignment
)expression_statement
(if_statement
(boolean_operator
(not_operator
(attribute
(identifier_self) identifier_self
(identifier_data) identifier_data
)attribute
)not_operator
(comparison_operator
(identifier_start) identifier_start
(attribute
(identifier_self) identifier_self
(identifier_expires) identifier_expires
)attribute
)comparison_operator
)boolean_operator
(block
(expression_statement
(assignment
(attribute
(identifier_self) identifier_self
(identifier_data) identifier_data
)attribute
(call
(attribute
(identifier_self) identifier_self
(identifier__get_context_from_gdoc) identifier__get_context_from_gdoc
)attribute
(argument_list
(attribute
(attribute
(identifier_self) identifier_self
(identifier_project) identifier_project
)attribute
(identifier_SPREADSHEET_KEY) identifier_SPREADSHEET_KEY
)attribute
)argument_list
)call
)assignment
)expression_statement
(expression_statement
(assignment
(identifier_end) identifier_end
(call
(identifier_int) identifier_int
(argument_list
(call
(attribute
(identifier_time) identifier_time
(identifier_time) identifier_time
)attribute
(argument_list
)argument_list
)call
)argument_list
)call
)assignment
)expression_statement
(expression_statement
(assignment
(identifier_ttl) identifier_ttl
(call
(identifier_getattr) identifier_getattr
(argument_list
(attribute
(identifier_self) identifier_self
(identifier_project) identifier_project
)attribute
(string_'SPREADSHEET_CACHE_TTL') string_'SPREADSHEET_CACHE_TTL'
(identifier_SPREADSHEET_CACHE_TTL) identifier_SPREADSHEET_CACHE_TTL
)argument_list
)call
)assignment
)expression_statement
(expression_statement
(assignment
(attribute
(identifier_self) identifier_self
(identifier_expires) identifier_expires
)attribute
(binary_operator
(identifier_end) identifier_end
(identifier_ttl) identifier_ttl
)binary_operator
)assignment
)expression_statement
)block
)if_statement
(return_statement
(attribute
(identifier_self) identifier_self
(identifier_data) identifier_data
)attribute
)return_statement
)block
(except_clause
(identifier_AttributeError) identifier_AttributeError
(block
(return_statement
(dictionary
)dictionary
)return_statement
)block
)except_clause
)try_statement
)block
)function_definition
)module | Wrap getting context from Google sheets in a simple caching mechanism. |
(module
(function_definition
(function_name_addFollowOnFn) function_name_addFollowOnFn
(parameters
(identifier_self) identifier_self
(identifier_fn) identifier_fn
(list_splat_pattern
(identifier_args) identifier_args
)list_splat_pattern
(dictionary_splat_pattern
(identifier_kwargs) identifier_kwargs
)dictionary_splat_pattern
)parameters
(block
(if_statement
(call
(attribute
(identifier_PromisedRequirement) identifier_PromisedRequirement
(identifier_convertPromises) identifier_convertPromises
)attribute
(argument_list
(identifier_kwargs) identifier_kwargs
)argument_list
)call
(block
(return_statement
(call
(attribute
(identifier_self) identifier_self
(identifier_addFollowOn) identifier_addFollowOn
)attribute
(argument_list
(call
(attribute
(identifier_PromisedRequirementFunctionWrappingJob) identifier_PromisedRequirementFunctionWrappingJob
(identifier_create) identifier_create
)attribute
(argument_list
(identifier_fn) identifier_fn
(list_splat
(identifier_args) identifier_args
)list_splat
(dictionary_splat
(identifier_kwargs) identifier_kwargs
)dictionary_splat
)argument_list
)call
)argument_list
)call
)return_statement
)block
(else_clause
(block
(return_statement
(call
(attribute
(identifier_self) identifier_self
(identifier_addFollowOn) identifier_addFollowOn
)attribute
(argument_list
(call
(identifier_FunctionWrappingJob) identifier_FunctionWrappingJob
(argument_list
(identifier_fn) identifier_fn
(list_splat
(identifier_args) identifier_args
)list_splat
(dictionary_splat
(identifier_kwargs) identifier_kwargs
)dictionary_splat
)argument_list
)call
)argument_list
)call
)return_statement
)block
)else_clause
)if_statement
)block
)function_definition
)module | Adds a function as a follow-on job.
:param fn: Function to be run as a follow-on job with ``*args`` and ``**kwargs`` as \
arguments to this function. See toil.job.FunctionWrappingJob for reserved \
keyword arguments used to specify resource requirements.
:return: The new follow-on job that wraps fn.
:rtype: toil.job.FunctionWrappingJob |
(module
(function_definition
(function_name_set_prob_type) function_name_set_prob_type
(parameters
(identifier_cls) identifier_cls
(identifier_problem_type) identifier_problem_type
(identifier_classification_type) identifier_classification_type
(identifier_eval_type) identifier_eval_type
)parameters
(block
(assert_statement
(comparison_operator
(identifier_problem_type) identifier_problem_type
(identifier_problem_type_list) identifier_problem_type_list
)comparison_operator
(string_'Need to set Problem Type') string_'Need to set Problem Type'
)assert_statement
(if_statement
(comparison_operator
(identifier_problem_type) identifier_problem_type
(string_'classification') string_'classification'
)comparison_operator
(block
(assert_statement
(comparison_operator
(identifier_classification_type) identifier_classification_type
(identifier_classification_type_list) identifier_classification_type_list
)comparison_operator
(string_'Need to set Classification Type') string_'Need to set Classification Type'
)assert_statement
)block
)if_statement
(assert_statement
(comparison_operator
(identifier_eval_type) identifier_eval_type
(identifier_eval_type_list) identifier_eval_type_list
)comparison_operator
(string_'Need to set Evaluation Type') string_'Need to set Evaluation Type'
)assert_statement
(expression_statement
(assignment
(attribute
(identifier_cls) identifier_cls
(identifier_problem_type) identifier_problem_type
)attribute
(identifier_problem_type) identifier_problem_type
)assignment
)expression_statement
(expression_statement
(assignment
(attribute
(identifier_cls) identifier_cls
(identifier_classification_type) identifier_classification_type
)attribute
(identifier_classification_type) identifier_classification_type
)assignment
)expression_statement
(expression_statement
(assignment
(attribute
(identifier_cls) identifier_cls
(identifier_eval_type) identifier_eval_type
)attribute
(identifier_eval_type) identifier_eval_type
)assignment
)expression_statement
(if_statement
(comparison_operator
(attribute
(identifier_cls) identifier_cls
(identifier_problem_type) identifier_problem_type
)attribute
(string_'classification') string_'classification'
)comparison_operator
(block
(print_statement
(call
(attribute
(string_'Setting Problem:{}, Type:{}, Eval:{}') string_'Setting Problem:{}, Type:{}, Eval:{}'
(identifier_format) identifier_format
)attribute
(argument_list
(attribute
(identifier_cls) identifier_cls
(identifier_problem_type) identifier_problem_type
)attribute
(attribute
(identifier_cls) identifier_cls
(identifier_classification_type) identifier_classification_type
)attribute
(attribute
(identifier_cls) identifier_cls
(identifier_eval_type) identifier_eval_type
)attribute
)argument_list
)call
)print_statement
)block
(elif_clause
(comparison_operator
(attribute
(identifier_cls) identifier_cls
(identifier_problem_type) identifier_problem_type
)attribute
(string_'regression') string_'regression'
)comparison_operator
(block
(print_statement
(call
(attribute
(string_'Setting Problem:{}, Eval:{}') string_'Setting Problem:{}, Eval:{}'
(identifier_format) identifier_format
)attribute
(argument_list
(attribute
(identifier_cls) identifier_cls
(identifier_problem_type) identifier_problem_type
)attribute
(attribute
(identifier_cls) identifier_cls
(identifier_eval_type) identifier_eval_type
)attribute
)argument_list
)call
)print_statement
)block
)elif_clause
)if_statement
(return_statement
)return_statement
)block
)function_definition
)module | Set problem type |
(module
(function_definition
(function_name__simplify_block) function_name__simplify_block
(parameters
(identifier_self) identifier_self
(identifier_ail_block) identifier_ail_block
(default_parameter
(identifier_stack_pointer_tracker) identifier_stack_pointer_tracker
(None) None
)default_parameter
)parameters
(block
(expression_statement
(assignment
(identifier_simp) identifier_simp
(call
(attribute
(attribute
(attribute
(identifier_self) identifier_self
(identifier_project) identifier_project
)attribute
(identifier_analyses) identifier_analyses
)attribute
(identifier_AILBlockSimplifier) identifier_AILBlockSimplifier
)attribute
(argument_list
(identifier_ail_block) identifier_ail_block
(keyword_argument
(identifier_stack_pointer_tracker) identifier_stack_pointer_tracker
(identifier_stack_pointer_tracker) identifier_stack_pointer_tracker
)keyword_argument
)argument_list
)call
)assignment
)expression_statement
(return_statement
(attribute
(identifier_simp) identifier_simp
(identifier_result_block) identifier_result_block
)attribute
)return_statement
)block
)function_definition
)module | Simplify a single AIL block.
:param ailment.Block ail_block: The AIL block to simplify.
:param stack_pointer_tracker: The RegisterDeltaTracker analysis instance.
:return: A simplified AIL block. |
(module
(function_definition
(function_name_get_unicode_str) function_name_get_unicode_str
(parameters
(identifier_obj) identifier_obj
)parameters
(block
(if_statement
(call
(identifier_isinstance) identifier_isinstance
(argument_list
(identifier_obj) identifier_obj
(attribute
(identifier_six) identifier_six
(identifier_text_type) identifier_text_type
)attribute
)argument_list
)call
(block
(return_statement
(identifier_obj) identifier_obj
)return_statement
)block
)if_statement
(if_statement
(call
(identifier_isinstance) identifier_isinstance
(argument_list
(identifier_obj) identifier_obj
(attribute
(identifier_six) identifier_six
(identifier_binary_type) identifier_binary_type
)attribute
)argument_list
)call
(block
(return_statement
(call
(attribute
(identifier_obj) identifier_obj
(identifier_decode) identifier_decode
)attribute
(argument_list
(string_"utf-8") string_"utf-8"
(keyword_argument
(identifier_errors) identifier_errors
(string_"ignore") string_"ignore"
)keyword_argument
)argument_list
)call
)return_statement
)block
)if_statement
(return_statement
(call
(attribute
(identifier_six) identifier_six
(identifier_text_type) identifier_text_type
)attribute
(argument_list
(identifier_obj) identifier_obj
)argument_list
)call
)return_statement
)block
)function_definition
)module | Makes sure obj is a unicode string. |
(module
(function_definition
(function_name__setweights) function_name__setweights
(parameters
(identifier_self) identifier_self
)parameters
(block
(for_statement
(identifier_name_w) identifier_name_w
(attribute
(identifier_self) identifier_self
(identifier_weights) identifier_weights
)attribute
(block
(expression_statement
(assignment
(identifier_raw_w) identifier_raw_w
(call
(identifier_getattr) identifier_getattr
(argument_list
(attribute
(identifier_self) identifier_self
(identifier_module) identifier_module
)attribute
(binary_operator
(identifier_name_w) identifier_name_w
(string_'_raw') string_'_raw'
)binary_operator
)argument_list
)call
)assignment
)expression_statement
(expression_statement
(assignment
(identifier_w) identifier_w
(call
(attribute
(attribute
(attribute
(identifier_torch) identifier_torch
(identifier_nn) identifier_nn
)attribute
(identifier_functional) identifier_functional
)attribute
(identifier_dropout) identifier_dropout
)attribute
(argument_list
(identifier_raw_w) identifier_raw_w
(keyword_argument
(identifier_p) identifier_p
(attribute
(identifier_self) identifier_self
(identifier_dropout) identifier_dropout
)attribute
)keyword_argument
(keyword_argument
(identifier_training) identifier_training
(attribute
(identifier_self) identifier_self
(identifier_training) identifier_training
)attribute
)keyword_argument
)argument_list
)call
)assignment
)expression_statement
(if_statement
(call
(identifier_hasattr) identifier_hasattr
(argument_list
(attribute
(identifier_self) identifier_self
(identifier_module) identifier_module
)attribute
(identifier_name_w) identifier_name_w
)argument_list
)call
(block
(expression_statement
(call
(identifier_delattr) identifier_delattr
(argument_list
(attribute
(identifier_self) identifier_self
(identifier_module) identifier_module
)attribute
(identifier_name_w) identifier_name_w
)argument_list
)call
)expression_statement
)block
)if_statement
(expression_statement
(call
(identifier_setattr) identifier_setattr
(argument_list
(attribute
(identifier_self) identifier_self
(identifier_module) identifier_module
)attribute
(identifier_name_w) identifier_name_w
(identifier_w) identifier_w
)argument_list
)call
)expression_statement
)block
)for_statement
)block
)function_definition
)module | Uses pytorch's built-in dropout function to apply dropout to the parameters of
the wrapped module.
Args:
None
Returns:
None |
(module
(function_definition
(function_name_run) function_name_run
(parameters
(identifier_self) identifier_self
)parameters
(block
(expression_statement
(assignment
(identifier_cmd) identifier_cmd
(call
(identifier_list) identifier_list
(argument_list
(attribute
(identifier_self) identifier_self
(identifier_vasp_cmd) identifier_vasp_cmd
)attribute
)argument_list
)call
)assignment
)expression_statement
(if_statement
(attribute
(identifier_self) identifier_self
(identifier_auto_gamma) identifier_auto_gamma
)attribute
(block
(expression_statement
(assignment
(identifier_vi) identifier_vi
(call
(attribute
(identifier_VaspInput) identifier_VaspInput
(identifier_from_directory) identifier_from_directory
)attribute
(argument_list
(string_".") string_"."
)argument_list
)call
)assignment
)expression_statement
(expression_statement
(assignment
(identifier_kpts) identifier_kpts
(subscript
(identifier_vi) identifier_vi
(string_"KPOINTS") string_"KPOINTS"
)subscript
)assignment
)expression_statement
(if_statement
(boolean_operator
(comparison_operator
(attribute
(identifier_kpts) identifier_kpts
(identifier_style) identifier_style
)attribute
(attribute
(attribute
(identifier_Kpoints) identifier_Kpoints
(identifier_supported_modes) identifier_supported_modes
)attribute
(identifier_Gamma) identifier_Gamma
)attribute
)comparison_operator
(line_continuation_\) line_continuation_\
(comparison_operator
(call
(identifier_tuple) identifier_tuple
(argument_list
(subscript
(attribute
(identifier_kpts) identifier_kpts
(identifier_kpts) identifier_kpts
)attribute
(integer_0) integer_0
)subscript
)argument_list
)call
(tuple
(integer_1) integer_1
(integer_1) integer_1
(integer_1) integer_1
)tuple
)comparison_operator
)boolean_operator
(block
(if_statement
(boolean_operator
(comparison_operator
(attribute
(identifier_self) identifier_self
(identifier_gamma_vasp_cmd) identifier_gamma_vasp_cmd
)attribute
(None) None
)comparison_operator
(call
(identifier_which) identifier_which
(argument_list
(subscript
(attribute
(identifier_self) identifier_self
(identifier_gamma_vasp_cmd) identifier_gamma_vasp_cmd
)attribute
(unary_operator
(integer_1) integer_1
)unary_operator
)subscript
)argument_list
)call
)boolean_operator
(block
(expression_statement
(assignment
(identifier_cmd) identifier_cmd
(attribute
(identifier_self) identifier_self
(identifier_gamma_vasp_cmd) identifier_gamma_vasp_cmd
)attribute
)assignment
)expression_statement
)block
(elif_clause
(call
(identifier_which) identifier_which
(argument_list
(binary_operator
(subscript
(identifier_cmd) identifier_cmd
(unary_operator
(integer_1) integer_1
)unary_operator
)subscript
(string_".gamma") string_".gamma"
)binary_operator
)argument_list
)call
(block
(expression_statement
(augmented_assignment
(subscript
(identifier_cmd) identifier_cmd
(unary_operator
(integer_1) integer_1
)unary_operator
)subscript
(string_".gamma") string_".gamma"
)augmented_assignment
)expression_statement
)block
)elif_clause
)if_statement
)block
)if_statement
)block
)if_statement
(expression_statement
(call
(attribute
(identifier_logger) identifier_logger
(identifier_info) identifier_info
)attribute
(argument_list
(call
(attribute
(string_"Running {}") string_"Running {}"
(identifier_format) identifier_format
)attribute
(argument_list
(call
(attribute
(string_" ") string_" "
(identifier_join) identifier_join
)attribute
(argument_list
(identifier_cmd) identifier_cmd
)argument_list
)call
)argument_list
)call
)argument_list
)call
)expression_statement
(with_statement
(with_clause
(with_item
(as_pattern
(call
(identifier_open) identifier_open
(argument_list
(attribute
(identifier_self) identifier_self
(identifier_output_file) identifier_output_file
)attribute
(string_'w') string_'w'
)argument_list
)call
(as_pattern_target
(identifier_f_std) identifier_f_std
)as_pattern_target
)as_pattern
)with_item
(line_continuation_\) line_continuation_\
(with_item
(as_pattern
(call
(identifier_open) identifier_open
(argument_list
(attribute
(identifier_self) identifier_self
(identifier_stderr_file) identifier_stderr_file
)attribute
(string_"w") string_"w"
(keyword_argument
(identifier_buffering) identifier_buffering
(integer_1) integer_1
)keyword_argument
)argument_list
)call
(as_pattern_target
(identifier_f_err) identifier_f_err
)as_pattern_target
)as_pattern
)with_item
)with_clause
(block
(expression_statement
(assignment
(identifier_p) identifier_p
(call
(attribute
(identifier_subprocess) identifier_subprocess
(identifier_Popen) identifier_Popen
)attribute
(argument_list
(identifier_cmd) identifier_cmd
(keyword_argument
(identifier_stdout) identifier_stdout
(identifier_f_std) identifier_f_std
)keyword_argument
(keyword_argument
(identifier_stderr) identifier_stderr
(identifier_f_err) identifier_f_err
)keyword_argument
)argument_list
)call
)assignment
)expression_statement
)block
)with_statement
(return_statement
(identifier_p) identifier_p
)return_statement
)block
)function_definition
)module | Perform the actual VASP run.
Returns:
(subprocess.Popen) Used for monitoring. |
(module
(function_definition
(function_name_total_items) function_name_total_items
(parameters
(identifier_self) identifier_self
(identifier_request) identifier_request
)parameters
(block
(expression_statement
(assignment
(identifier_n_total) identifier_n_total
(integer_0) integer_0
)assignment
)expression_statement
(for_statement
(identifier_item) identifier_item
(call
(attribute
(identifier_self) identifier_self
(identifier_get_queryset) identifier_get_queryset
)attribute
(argument_list
(identifier_request) identifier_request
)argument_list
)call
(block
(expression_statement
(augmented_assignment
(identifier_n_total) identifier_n_total
(attribute
(identifier_item) identifier_item
(identifier_quantity) identifier_quantity
)attribute
)augmented_assignment
)expression_statement
)block
)for_statement
(return_statement
(call
(identifier_Response) identifier_Response
(argument_list
(keyword_argument
(identifier_data) identifier_data
(dictionary
(pair
(string_"quantity") string_"quantity"
(identifier_n_total) identifier_n_total
)pair
)dictionary
)keyword_argument
(keyword_argument
(identifier_status) identifier_status
(attribute
(identifier_status) identifier_status
(identifier_HTTP_200_OK) identifier_HTTP_200_OK
)attribute
)keyword_argument
)argument_list
)call
)return_statement
)block
)function_definition
)module | Get total number of items in the basket |
(module
(function_definition
(function_name_get_finder) function_name_get_finder
(parameters
(default_parameter
(identifier_sources) identifier_sources
(None) None
)default_parameter
(default_parameter
(identifier_pip_command) identifier_pip_command
(None) None
)default_parameter
(default_parameter
(identifier_pip_options) identifier_pip_options
(None) None
)default_parameter
)parameters
(block
(if_statement
(not_operator
(identifier_pip_command) identifier_pip_command
)not_operator
(block
(expression_statement
(assignment
(identifier_pip_command) identifier_pip_command
(call
(identifier_get_pip_command) identifier_get_pip_command
(argument_list
)argument_list
)call
)assignment
)expression_statement
)block
)if_statement
(if_statement
(not_operator
(identifier_sources) identifier_sources
)not_operator
(block
(expression_statement
(assignment
(identifier_sources) identifier_sources
(list
(dictionary
(pair
(string_"url") string_"url"
(string_"https://pypi.org/simple") string_"https://pypi.org/simple"
)pair
(pair
(string_"name") string_"name"
(string_"pypi") string_"pypi"
)pair
(pair
(string_"verify_ssl") string_"verify_ssl"
(True) True
)pair
)dictionary
)list
)assignment
)expression_statement
)block
)if_statement
(if_statement
(not_operator
(identifier_pip_options) identifier_pip_options
)not_operator
(block
(expression_statement
(assignment
(identifier_pip_options) identifier_pip_options
(call
(identifier_get_pip_options) identifier_get_pip_options
(argument_list
(keyword_argument
(identifier_sources) identifier_sources
(identifier_sources) identifier_sources
)keyword_argument
(keyword_argument
(identifier_pip_command) identifier_pip_command
(identifier_pip_command) identifier_pip_command
)keyword_argument
)argument_list
)call
)assignment
)expression_statement
)block
)if_statement
(expression_statement
(assignment
(identifier_session) identifier_session
(call
(attribute
(identifier_pip_command) identifier_pip_command
(identifier__build_session) identifier__build_session
)attribute
(argument_list
(identifier_pip_options) identifier_pip_options
)argument_list
)call
)assignment
)expression_statement
(expression_statement
(call
(attribute
(identifier_atexit) identifier_atexit
(identifier_register) identifier_register
)attribute
(argument_list
(attribute
(identifier_session) identifier_session
(identifier_close) identifier_close
)attribute
)argument_list
)call
)expression_statement
(expression_statement
(assignment
(identifier_finder) identifier_finder
(call
(attribute
(attribute
(identifier_pip_shims) identifier_pip_shims
(identifier_shims) identifier_shims
)attribute
(identifier_PackageFinder) identifier_PackageFinder
)attribute
(argument_list
(keyword_argument
(identifier_find_links) identifier_find_links
(list
)list
)keyword_argument
(keyword_argument
(identifier_index_urls) identifier_index_urls
(list_comprehension
(call
(attribute
(identifier_s) identifier_s
(identifier_get) identifier_get
)attribute
(argument_list
(string_"url") string_"url"
)argument_list
)call
(for_in_clause
(identifier_s) identifier_s
(identifier_sources) identifier_sources
)for_in_clause
)list_comprehension
)keyword_argument
(keyword_argument
(identifier_trusted_hosts) identifier_trusted_hosts
(list
)list
)keyword_argument
(keyword_argument
(identifier_allow_all_prereleases) identifier_allow_all_prereleases
(attribute
(identifier_pip_options) identifier_pip_options
(identifier_pre) identifier_pre
)attribute
)keyword_argument
(keyword_argument
(identifier_session) identifier_session
(identifier_session) identifier_session
)keyword_argument
)argument_list
)call
)assignment
)expression_statement
(return_statement
(identifier_finder) identifier_finder
)return_statement
)block
)function_definition
)module | Get a package finder for looking up candidates to install
:param sources: A list of pipfile-formatted sources, defaults to None
:param sources: list[dict], optional
:param pip_command: A pip command instance, defaults to None
:type pip_command: :class:`~pip._internal.cli.base_command.Command`
:param pip_options: A pip options, defaults to None
:type pip_options: :class:`~pip._internal.cli.cmdoptions`
:return: A package finder
:rtype: :class:`~pip._internal.index.PackageFinder` |
(module
(function_definition
(function_name_ActionEnum) function_name_ActionEnum
(parameters
(identifier_ctx) identifier_ctx
)parameters
(block
(return_statement
(call
(identifier_Enum) identifier_Enum
(argument_list
(identifier_ctx) identifier_ctx
(keyword_argument
(identifier_interact) identifier_interact
(integer_0) integer_0
)keyword_argument
(keyword_argument
(identifier_stop) identifier_stop
(integer_1) integer_1
)keyword_argument
(keyword_argument
(identifier_ai_interact) identifier_ai_interact
(integer_2) integer_2
)keyword_argument
(keyword_argument
(identifier_move) identifier_move
(integer_3) integer_3
)keyword_argument
(keyword_argument
(identifier_add_attribute) identifier_add_attribute
(integer_5) integer_5
)keyword_argument
(keyword_argument
(identifier_give_attribute) identifier_give_attribute
(integer_6) integer_6
)keyword_argument
(keyword_argument
(identifier_ai_move) identifier_ai_move
(integer_10) integer_10
)keyword_argument
(keyword_argument
(identifier_resign) identifier_resign
(integer_11) integer_11
)keyword_argument
(keyword_argument
(identifier_spec) identifier_spec
(integer_15) integer_15
)keyword_argument
(keyword_argument
(identifier_waypoint) identifier_waypoint
(integer_16) integer_16
)keyword_argument
(keyword_argument
(identifier_stance) identifier_stance
(integer_18) integer_18
)keyword_argument
(keyword_argument
(identifier_guard) identifier_guard
(integer_19) integer_19
)keyword_argument
(keyword_argument
(identifier_follow) identifier_follow
(integer_20) integer_20
)keyword_argument
(keyword_argument
(identifier_patrol) identifier_patrol
(integer_21) integer_21
)keyword_argument
(keyword_argument
(identifier_formation) identifier_formation
(integer_23) integer_23
)keyword_argument
(keyword_argument
(identifier_save) identifier_save
(integer_27) integer_27
)keyword_argument
(keyword_argument
(identifier_ai_waypoint) identifier_ai_waypoint
(integer_31) integer_31
)keyword_argument
(keyword_argument
(identifier_chapter) identifier_chapter
(integer_32) integer_32
)keyword_argument
(keyword_argument
(identifier_ai_command) identifier_ai_command
(integer_53) integer_53
)keyword_argument
(keyword_argument
(identifier_ai_queue) identifier_ai_queue
(integer_100) integer_100
)keyword_argument
(keyword_argument
(identifier_research) identifier_research
(integer_101) integer_101
)keyword_argument
(keyword_argument
(identifier_build) identifier_build
(integer_102) integer_102
)keyword_argument
(keyword_argument
(identifier_game) identifier_game
(integer_103) integer_103
)keyword_argument
(keyword_argument
(identifier_wall) identifier_wall
(integer_105) integer_105
)keyword_argument
(keyword_argument
(identifier_delete) identifier_delete
(integer_106) integer_106
)keyword_argument
(keyword_argument
(identifier_attackground) identifier_attackground
(integer_107) integer_107
)keyword_argument
(keyword_argument
(identifier_tribute) identifier_tribute
(integer_108) integer_108
)keyword_argument
(keyword_argument
(identifier_repair) identifier_repair
(integer_110) integer_110
)keyword_argument
(keyword_argument
(identifier_release) identifier_release
(integer_111) integer_111
)keyword_argument
(keyword_argument
(identifier_multiqueue) identifier_multiqueue
(integer_112) integer_112
)keyword_argument
(keyword_argument
(identifier_togglegate) identifier_togglegate
(integer_114) integer_114
)keyword_argument
(keyword_argument
(identifier_flare) identifier_flare
(integer_115) integer_115
)keyword_argument
(keyword_argument
(identifier_order) identifier_order
(integer_117) integer_117
)keyword_argument
(keyword_argument
(identifier_queue) identifier_queue
(integer_119) integer_119
)keyword_argument
(keyword_argument
(identifier_gatherpoint) identifier_gatherpoint
(integer_120) integer_120
)keyword_argument
(keyword_argument
(identifier_sell) identifier_sell
(integer_122) integer_122
)keyword_argument
(keyword_argument
(identifier_buy) identifier_buy
(integer_123) integer_123
)keyword_argument
(keyword_argument
(identifier_droprelic) identifier_droprelic
(integer_126) integer_126
)keyword_argument
(keyword_argument
(identifier_townbell) identifier_townbell
(integer_127) integer_127
)keyword_argument
(keyword_argument
(identifier_backtowork) identifier_backtowork
(integer_128) integer_128
)keyword_argument
(keyword_argument
(identifier_postgame) identifier_postgame
(integer_255) integer_255
)keyword_argument
(keyword_argument
(identifier_default) identifier_default
(identifier_Pass) identifier_Pass
)keyword_argument
)argument_list
)call
)return_statement
)block
)function_definition
)module | Action Enumeration. |
(module
(function_definition
(function_name_allow_unconfirmed_email) function_name_allow_unconfirmed_email
(parameters
(identifier_view_function) identifier_view_function
)parameters
(block
(decorated_definition
(decorator
(call
(identifier_wraps) identifier_wraps
(argument_list
(identifier_view_function) identifier_view_function
)argument_list
)call
)decorator
(function_definition
(function_name_decorator) function_name_decorator
(parameters
(list_splat_pattern
(identifier_args) identifier_args
)list_splat_pattern
(dictionary_splat_pattern
(identifier_kwargs) identifier_kwargs
)dictionary_splat_pattern
)parameters
(block
(expression_statement
(assignment
(attribute
(identifier_g) identifier_g
(identifier__flask_user_allow_unconfirmed_email) identifier__flask_user_allow_unconfirmed_email
)attribute
(True) True
)assignment
)expression_statement
(try_statement
(block
(expression_statement
(assignment
(identifier_user_manager) identifier_user_manager
(attribute
(identifier_current_app) identifier_current_app
(identifier_user_manager) identifier_user_manager
)attribute
)assignment
)expression_statement
(expression_statement
(assignment
(identifier_allowed) identifier_allowed
(call
(identifier__is_logged_in_with_confirmed_email) identifier__is_logged_in_with_confirmed_email
(argument_list
(identifier_user_manager) identifier_user_manager
)argument_list
)call
)assignment
)expression_statement
(if_statement
(not_operator
(identifier_allowed) identifier_allowed
)not_operator
(block
(return_statement
(call
(attribute
(identifier_user_manager) identifier_user_manager
(identifier_unauthenticated_view) identifier_unauthenticated_view
)attribute
(argument_list
)argument_list
)call
)return_statement
)block
)if_statement
(return_statement
(call
(identifier_view_function) identifier_view_function
(argument_list
(list_splat
(identifier_args) identifier_args
)list_splat
(dictionary_splat
(identifier_kwargs) identifier_kwargs
)dictionary_splat
)argument_list
)call
)return_statement
)block
(finally_clause
(block
(expression_statement
(assignment
(attribute
(identifier_g) identifier_g
(identifier__flask_user_allow_unconfirmed_email) identifier__flask_user_allow_unconfirmed_email
)attribute
(False) False
)assignment
)expression_statement
)block
)finally_clause
)try_statement
)block
)function_definition
)decorated_definition
(return_statement
(identifier_decorator) identifier_decorator
)return_statement
)block
)function_definition
)module | This decorator ensures that the user is logged in,
but allows users with or without a confirmed email addresses
to access this particular view.
It works in tandem with the ``USER_ALLOW_LOGIN_WITHOUT_CONFIRMED_EMAIL=True`` setting.
.. caution::
| Use ``USER_ALLOW_LOGIN_WITHOUT_CONFIRMED_EMAIL=True`` and
``@allow_unconfirmed_email`` with caution,
as they relax security requirements.
| Make sure that decorated views **never call other views directly**.
Allways use ``redirect()`` to ensure proper view protection.
Example::
@route('/show_promotion')
@allow_unconfirmed_emails
def show_promotion(): # Logged in, with or without
... # confirmed email address
It can also precede the ``@roles_required`` and ``@roles_accepted`` view decorators::
@route('/show_promotion')
@allow_unconfirmed_emails
@roles_required('Visitor')
def show_promotion(): # Logged in, with or without
... # confirmed email address
| Calls unauthorized_view() when the user is not logged in.
| Calls the decorated view otherwise. |
(module
(function_definition
(function_name_update_dataset) function_name_update_dataset
(parameters
(identifier_self) identifier_self
(identifier_dataset) identifier_dataset
(identifier_fields) identifier_fields
(default_parameter
(identifier_retry) identifier_retry
(identifier_DEFAULT_RETRY) identifier_DEFAULT_RETRY
)default_parameter
)parameters
(block
(expression_statement
(assignment
(identifier_partial) identifier_partial
(call
(attribute
(identifier_dataset) identifier_dataset
(identifier__build_resource) identifier__build_resource
)attribute
(argument_list
(identifier_fields) identifier_fields
)argument_list
)call
)assignment
)expression_statement
(if_statement
(comparison_operator
(attribute
(identifier_dataset) identifier_dataset
(identifier_etag) identifier_etag
)attribute
(None) None
)comparison_operator
(block
(expression_statement
(assignment
(identifier_headers) identifier_headers
(dictionary
(pair
(string_"If-Match") string_"If-Match"
(attribute
(identifier_dataset) identifier_dataset
(identifier_etag) identifier_etag
)attribute
)pair
)dictionary
)assignment
)expression_statement
)block
(else_clause
(block
(expression_statement
(assignment
(identifier_headers) identifier_headers
(None) None
)assignment
)expression_statement
)block
)else_clause
)if_statement
(expression_statement
(assignment
(identifier_api_response) identifier_api_response
(call
(attribute
(identifier_self) identifier_self
(identifier__call_api) identifier__call_api
)attribute
(argument_list
(identifier_retry) identifier_retry
(keyword_argument
(identifier_method) identifier_method
(string_"PATCH") string_"PATCH"
)keyword_argument
(keyword_argument
(identifier_path) identifier_path
(attribute
(identifier_dataset) identifier_dataset
(identifier_path) identifier_path
)attribute
)keyword_argument
(keyword_argument
(identifier_data) identifier_data
(identifier_partial) identifier_partial
)keyword_argument
(keyword_argument
(identifier_headers) identifier_headers
(identifier_headers) identifier_headers
)keyword_argument
)argument_list
)call
)assignment
)expression_statement
(return_statement
(call
(attribute
(identifier_Dataset) identifier_Dataset
(identifier_from_api_repr) identifier_from_api_repr
)attribute
(argument_list
(identifier_api_response) identifier_api_response
)argument_list
)call
)return_statement
)block
)function_definition
)module | Change some fields of a dataset.
Use ``fields`` to specify which fields to update. At least one field
must be provided. If a field is listed in ``fields`` and is ``None`` in
``dataset``, it will be deleted.
If ``dataset.etag`` is not ``None``, the update will only
succeed if the dataset on the server has the same ETag. Thus
reading a dataset with ``get_dataset``, changing its fields,
and then passing it to ``update_dataset`` will ensure that the changes
will only be saved if no modifications to the dataset occurred
since the read.
Args:
dataset (google.cloud.bigquery.dataset.Dataset):
The dataset to update.
fields (Sequence[str]):
The properties of ``dataset`` to change (e.g. "friendly_name").
retry (google.api_core.retry.Retry, optional):
How to retry the RPC.
Returns:
google.cloud.bigquery.dataset.Dataset:
The modified ``Dataset`` instance. |
(module
(function_definition
(function_name_get_predicate_indices) function_name_get_predicate_indices
(parameters
(typed_parameter
(identifier_tags) identifier_tags
(type
(generic_type
(identifier_List) identifier_List
(type_parameter
(type
(identifier_str) identifier_str
)type
)type_parameter
)generic_type
)type
)typed_parameter
)parameters
(type
(generic_type
(identifier_List) identifier_List
(type_parameter
(type
(identifier_int) identifier_int
)type
)type_parameter
)generic_type
)type
(block
(return_statement
(list_comprehension
(identifier_ind) identifier_ind
(for_in_clause
(pattern_list
(identifier_ind) identifier_ind
(identifier_tag) identifier_tag
)pattern_list
(call
(identifier_enumerate) identifier_enumerate
(argument_list
(identifier_tags) identifier_tags
)argument_list
)call
)for_in_clause
(if_clause
(comparison_operator
(string_'V') string_'V'
(identifier_tag) identifier_tag
)comparison_operator
)if_clause
)list_comprehension
)return_statement
)block
)function_definition
)module | Return the word indices of a predicate in BIO tags. |
(module
(function_definition
(function_name_remove) function_name_remove
(parameters
(identifier_self) identifier_self
(identifier_key) identifier_key
(default_parameter
(identifier_cas) identifier_cas
(integer_0) integer_0
)default_parameter
(default_parameter
(identifier_quiet) identifier_quiet
(None) None
)default_parameter
(default_parameter
(identifier_persist_to) identifier_persist_to
(integer_0) integer_0
)default_parameter
(default_parameter
(identifier_replicate_to) identifier_replicate_to
(integer_0) integer_0
)default_parameter
)parameters
(block
(return_statement
(call
(attribute
(identifier__Base) identifier__Base
(identifier_remove) identifier_remove
)attribute
(argument_list
(identifier_self) identifier_self
(identifier_key) identifier_key
(keyword_argument
(identifier_cas) identifier_cas
(identifier_cas) identifier_cas
)keyword_argument
(keyword_argument
(identifier_quiet) identifier_quiet
(identifier_quiet) identifier_quiet
)keyword_argument
(keyword_argument
(identifier_persist_to) identifier_persist_to
(identifier_persist_to) identifier_persist_to
)keyword_argument
(keyword_argument
(identifier_replicate_to) identifier_replicate_to
(identifier_replicate_to) identifier_replicate_to
)keyword_argument
)argument_list
)call
)return_statement
)block
)function_definition
)module | Remove the key-value entry for a given key in Couchbase.
:param key: A string which is the key to remove. The format and
type of the key follows the same conventions as in
:meth:`upsert`
:type key: string, dict, or tuple/list
:param int cas: The CAS to use for the removal operation.
If specified, the key will only be removed from the server
if it has the same CAS as specified. This is useful to
remove a key only if its value has not been changed from the
version currently visible to the client. If the CAS on the
server does not match the one specified, an exception is
thrown.
:param boolean quiet:
Follows the same semantics as `quiet` in :meth:`get`
:param int persist_to: If set, wait for the item to be removed
from the storage of at least these many nodes
:param int replicate_to: If set, wait for the item to be removed
from the cache of at least these many nodes
(excluding the master)
:raise: :exc:`.NotFoundError` if the key does not exist.
:raise: :exc:`.KeyExistsError` if a CAS was specified, but
the CAS on the server had changed
:return: A :class:`~.Result` object.
Simple remove::
ok = cb.remove("key").success
Don't complain if key does not exist::
ok = cb.remove("key", quiet=True)
Only remove if CAS matches our version::
rv = cb.get("key")
cb.remove("key", cas=rv.cas)
Remove multiple keys::
oks = cb.remove_multi(["key1", "key2", "key3"])
Remove multiple keys with CAS::
oks = cb.remove({
"key1" : cas1,
"key2" : cas2,
"key3" : cas3
})
.. seealso:: :meth:`remove_multi`, :meth:`endure`
for more information on the ``persist_to`` and
``replicate_to`` options. |
(module
(function_definition
(function_name_GMailer) function_name_GMailer
(parameters
(identifier_recipients) identifier_recipients
(identifier_username) identifier_username
(identifier_password) identifier_password
(default_parameter
(identifier_subject) identifier_subject
(string_'Log message from lggr.py') string_'Log message from lggr.py'
)default_parameter
)parameters
(block
(import_statement
(dotted_name
(identifier_smtplib) identifier_smtplib
)dotted_name
)import_statement
(expression_statement
(assignment
(identifier_srvr) identifier_srvr
(call
(attribute
(identifier_smtplib) identifier_smtplib
(identifier_SMTP) identifier_SMTP
)attribute
(argument_list
(string_'smtp.gmail.com') string_'smtp.gmail.com'
(integer_587) integer_587
)argument_list
)call
)assignment
)expression_statement
(expression_statement
(call
(attribute
(identifier_srvr) identifier_srvr
(identifier_ehlo) identifier_ehlo
)attribute
(argument_list
)argument_list
)call
)expression_statement
(expression_statement
(call
(attribute
(identifier_srvr) identifier_srvr
(identifier_starttls) identifier_starttls
)attribute
(argument_list
)argument_list
)call
)expression_statement
(expression_statement
(call
(attribute
(identifier_srvr) identifier_srvr
(identifier_ehlo) identifier_ehlo
)attribute
(argument_list
)argument_list
)call
)expression_statement
(expression_statement
(call
(attribute
(identifier_srvr) identifier_srvr
(identifier_login) identifier_login
)attribute
(argument_list
(identifier_username) identifier_username
(identifier_password) identifier_password
)argument_list
)call
)expression_statement
(if_statement
(not_operator
(parenthesized_expression
(boolean_operator
(call
(identifier_isinstance) identifier_isinstance
(argument_list
(identifier_recipients) identifier_recipients
(identifier_list) identifier_list
)argument_list
)call
(call
(identifier_isinstance) identifier_isinstance
(argument_list
(identifier_recipients) identifier_recipients
(identifier_tuple) identifier_tuple
)argument_list
)call
)boolean_operator
)parenthesized_expression
)not_operator
(block
(expression_statement
(assignment
(identifier_recipients) identifier_recipients
(list
(identifier_recipients) identifier_recipients
)list
)assignment
)expression_statement
)block
)if_statement
(expression_statement
(assignment
(identifier_gmail_sender) identifier_gmail_sender
(call
(attribute
(string_'{0}@gmail.com') string_'{0}@gmail.com'
(identifier_format) identifier_format
)attribute
(argument_list
(identifier_username) identifier_username
)argument_list
)call
)assignment
)expression_statement
(expression_statement
(assignment
(identifier_msg) identifier_msg
(binary_operator
(binary_operator
(binary_operator
(binary_operator
(string_'To: {0}\nFrom: ') string_'To: {0}\nFrom: '
(identifier_gmail_sender) identifier_gmail_sender
)binary_operator
(string_'\nSubject: ') string_'\nSubject: '
)binary_operator
(identifier_subject) identifier_subject
)binary_operator
(string_'\n') string_'\n'
)binary_operator
)assignment
)expression_statement
(expression_statement
(assignment
(identifier_msg) identifier_msg
(binary_operator
(identifier_msg) identifier_msg
(string_'\n{1}\n\n') string_'\n{1}\n\n'
)binary_operator
)assignment
)expression_statement
(try_statement
(block
(while_statement
(True) True
(block
(expression_statement
(assignment
(identifier_logstr) identifier_logstr
(parenthesized_expression
(yield
)yield
)parenthesized_expression
)assignment
)expression_statement
(for_statement
(identifier_rcp) identifier_rcp
(identifier_recipients) identifier_recipients
(block
(expression_statement
(assignment
(identifier_message) identifier_message
(call
(attribute
(identifier_msg) identifier_msg
(identifier_format) identifier_format
)attribute
(argument_list
(identifier_rcp) identifier_rcp
(identifier_logstr) identifier_logstr
)argument_list
)call
)assignment
)expression_statement
(expression_statement
(call
(attribute
(identifier_srvr) identifier_srvr
(identifier_sendmail) identifier_sendmail
)attribute
(argument_list
(identifier_gmail_sender) identifier_gmail_sender
(identifier_rcp) identifier_rcp
(identifier_message) identifier_message
)argument_list
)call
)expression_statement
)block
)for_statement
)block
)while_statement
)block
(except_clause
(identifier_GeneratorExit) identifier_GeneratorExit
(block
(expression_statement
(call
(attribute
(identifier_srvr) identifier_srvr
(identifier_quit) identifier_quit
)attribute
(argument_list
)argument_list
)call
)expression_statement
)block
)except_clause
)try_statement
)block
)function_definition
)module | Sends messages as emails to the given list
of recipients, from a GMail account. |
(module
(function_definition
(function_name_disable_napp) function_name_disable_napp
(parameters
(identifier_mgr) identifier_mgr
)parameters
(block
(if_statement
(call
(attribute
(identifier_mgr) identifier_mgr
(identifier_is_enabled) identifier_is_enabled
)attribute
(argument_list
)argument_list
)call
(block
(expression_statement
(call
(attribute
(identifier_LOG) identifier_LOG
(identifier_info) identifier_info
)attribute
(argument_list
(string_' Disabling...') string_' Disabling...'
)argument_list
)call
)expression_statement
(expression_statement
(call
(attribute
(identifier_mgr) identifier_mgr
(identifier_disable) identifier_disable
)attribute
(argument_list
)argument_list
)call
)expression_statement
(expression_statement
(call
(attribute
(identifier_LOG) identifier_LOG
(identifier_info) identifier_info
)attribute
(argument_list
(string_' Disabled.') string_' Disabled.'
)argument_list
)call
)expression_statement
)block
(else_clause
(block
(expression_statement
(call
(attribute
(identifier_LOG) identifier_LOG
(identifier_error) identifier_error
)attribute
(argument_list
(string_" NApp isn't enabled.") string_" NApp isn't enabled."
)argument_list
)call
)expression_statement
)block
)else_clause
)if_statement
)block
)function_definition
)module | Disable a NApp. |
(module
(function_definition
(function_name_service_running) function_name_service_running
(parameters
(identifier_service_name) identifier_service_name
(dictionary_splat_pattern
(identifier_kwargs) identifier_kwargs
)dictionary_splat_pattern
)parameters
(block
(if_statement
(call
(identifier_init_is_systemd) identifier_init_is_systemd
(argument_list
)argument_list
)call
(block
(return_statement
(call
(identifier_service) identifier_service
(argument_list
(string_'is-active') string_'is-active'
(identifier_service_name) identifier_service_name
)argument_list
)call
)return_statement
)block
(else_clause
(block
(if_statement
(call
(attribute
(attribute
(identifier_os) identifier_os
(identifier_path) identifier_path
)attribute
(identifier_exists) identifier_exists
)attribute
(argument_list
(call
(attribute
(identifier__UPSTART_CONF) identifier__UPSTART_CONF
(identifier_format) identifier_format
)attribute
(argument_list
(identifier_service_name) identifier_service_name
)argument_list
)call
)argument_list
)call
(block
(try_statement
(block
(expression_statement
(assignment
(identifier_cmd) identifier_cmd
(list
(string_'status') string_'status'
(identifier_service_name) identifier_service_name
)list
)assignment
)expression_statement
(for_statement
(pattern_list
(identifier_key) identifier_key
(identifier_value) identifier_value
)pattern_list
(call
(attribute
(identifier_six) identifier_six
(identifier_iteritems) identifier_iteritems
)attribute
(argument_list
(identifier_kwargs) identifier_kwargs
)argument_list
)call
(block
(expression_statement
(assignment
(identifier_parameter) identifier_parameter
(binary_operator
(string_'%s=%s') string_'%s=%s'
(tuple
(identifier_key) identifier_key
(identifier_value) identifier_value
)tuple
)binary_operator
)assignment
)expression_statement
(expression_statement
(call
(attribute
(identifier_cmd) identifier_cmd
(identifier_append) identifier_append
)attribute
(argument_list
(identifier_parameter) identifier_parameter
)argument_list
)call
)expression_statement
)block
)for_statement
(expression_statement
(assignment
(identifier_output) identifier_output
(call
(attribute
(call
(attribute
(identifier_subprocess) identifier_subprocess
(identifier_check_output) identifier_check_output
)attribute
(argument_list
(identifier_cmd) identifier_cmd
(keyword_argument
(identifier_stderr) identifier_stderr
(attribute
(identifier_subprocess) identifier_subprocess
(identifier_STDOUT) identifier_STDOUT
)attribute
)keyword_argument
)argument_list
)call
(identifier_decode) identifier_decode
)attribute
(argument_list
(string_'UTF-8') string_'UTF-8'
)argument_list
)call
)assignment
)expression_statement
)block
(except_clause
(attribute
(identifier_subprocess) identifier_subprocess
(identifier_CalledProcessError) identifier_CalledProcessError
)attribute
(block
(return_statement
(False) False
)return_statement
)block
)except_clause
(else_clause
(block
(if_statement
(parenthesized_expression
(boolean_operator
(boolean_operator
(comparison_operator
(string_"start/running") string_"start/running"
(identifier_output) identifier_output
)comparison_operator
(comparison_operator
(string_"is running") string_"is running"
(identifier_output) identifier_output
)comparison_operator
)boolean_operator
(comparison_operator
(string_"up and running") string_"up and running"
(identifier_output) identifier_output
)comparison_operator
)boolean_operator
)parenthesized_expression
(block
(return_statement
(True) True
)return_statement
)block
)if_statement
)block
)else_clause
)try_statement
)block
(elif_clause
(call
(attribute
(attribute
(identifier_os) identifier_os
(identifier_path) identifier_path
)attribute
(identifier_exists) identifier_exists
)attribute
(argument_list
(call
(attribute
(identifier__INIT_D_CONF) identifier__INIT_D_CONF
(identifier_format) identifier_format
)attribute
(argument_list
(identifier_service_name) identifier_service_name
)argument_list
)call
)argument_list
)call
(block
(return_statement
(call
(identifier_service) identifier_service
(argument_list
(string_'status') string_'status'
(identifier_service_name) identifier_service_name
)argument_list
)call
)return_statement
)block
)elif_clause
)if_statement
(return_statement
(False) False
)return_statement
)block
)else_clause
)if_statement
)block
)function_definition
)module | Determine whether a system service is running.
:param service_name: the name of the service
:param **kwargs: additional args to pass to the service command. This is
used to pass additional key=value arguments to the
service command line for managing specific instance
units (e.g. service ceph-osd status id=2). The kwargs
are ignored in systemd services. |
(module
(function_definition
(function_name_find_ignored_languages) function_name_find_ignored_languages
(parameters
(identifier_source) identifier_source
)parameters
(block
(for_statement
(tuple_pattern
(identifier_index) identifier_index
(identifier_line) identifier_line
)tuple_pattern
(call
(identifier_enumerate) identifier_enumerate
(argument_list
(call
(attribute
(identifier_source) identifier_source
(identifier_splitlines) identifier_splitlines
)attribute
(argument_list
)argument_list
)call
)argument_list
)call
(block
(expression_statement
(assignment
(identifier_match) identifier_match
(call
(attribute
(identifier_RSTCHECK_COMMENT_RE) identifier_RSTCHECK_COMMENT_RE
(identifier_match) identifier_match
)attribute
(argument_list
(identifier_line) identifier_line
)argument_list
)call
)assignment
)expression_statement
(if_statement
(identifier_match) identifier_match
(block
(expression_statement
(assignment
(identifier_key_and_value) identifier_key_and_value
(call
(attribute
(call
(attribute
(subscript
(identifier_line) identifier_line
(slice
(call
(attribute
(identifier_match) identifier_match
(identifier_end) identifier_end
)attribute
(argument_list
)argument_list
)call
(colon) colon
)slice
)subscript
(identifier_strip) identifier_strip
)attribute
(argument_list
)argument_list
)call
(identifier_split) identifier_split
)attribute
(argument_list
(string_'=') string_'='
)argument_list
)call
)assignment
)expression_statement
(if_statement
(comparison_operator
(call
(identifier_len) identifier_len
(argument_list
(identifier_key_and_value) identifier_key_and_value
)argument_list
)call
(integer_2) integer_2
)comparison_operator
(block
(raise_statement
(call
(identifier_Error) identifier_Error
(argument_list
(string_'Expected "key=value" syntax') string_'Expected "key=value" syntax'
(keyword_argument
(identifier_line_number) identifier_line_number
(binary_operator
(identifier_index) identifier_index
(integer_1) integer_1
)binary_operator
)keyword_argument
)argument_list
)call
)raise_statement
)block
)if_statement
(if_statement
(comparison_operator
(subscript
(identifier_key_and_value) identifier_key_and_value
(integer_0) integer_0
)subscript
(string_'ignore-language') string_'ignore-language'
)comparison_operator
(block
(for_statement
(identifier_language) identifier_language
(call
(attribute
(subscript
(identifier_key_and_value) identifier_key_and_value
(integer_1) integer_1
)subscript
(identifier_split) identifier_split
)attribute
(argument_list
(string_',') string_','
)argument_list
)call
(block
(expression_statement
(yield
(call
(attribute
(identifier_language) identifier_language
(identifier_strip) identifier_strip
)attribute
(argument_list
)argument_list
)call
)yield
)expression_statement
)block
)for_statement
)block
)if_statement
)block
)if_statement
)block
)for_statement
)block
)function_definition
)module | Yield ignored languages.
Languages are ignored via comment.
For example, to ignore C++, JSON, and Python:
>>> list(find_ignored_languages('''
... Example
... =======
...
... .. rstcheck: ignore-language=cpp,json
...
... .. rstcheck: ignore-language=python
... '''))
['cpp', 'json', 'python'] |
(module
(function_definition
(function_name_to_web_include) function_name_to_web_include
(parameters
(typed_parameter
(identifier_project) identifier_project
(type
(string_'projects.Project') string_'projects.Project'
)type
)typed_parameter
(typed_parameter
(identifier_file_path) identifier_file_path
(type
(identifier_str) identifier_str
)type
)typed_parameter
)parameters
(type
(identifier_WEB_INCLUDE) identifier_WEB_INCLUDE
)type
(block
(if_statement
(boolean_operator
(not_operator
(call
(attribute
(identifier_file_path) identifier_file_path
(identifier_endswith) identifier_endswith
)attribute
(argument_list
(string_'.css') string_'.css'
)argument_list
)call
)not_operator
(not_operator
(call
(attribute
(identifier_file_path) identifier_file_path
(identifier_endswith) identifier_endswith
)attribute
(argument_list
(string_'.js') string_'.js'
)argument_list
)call
)not_operator
)boolean_operator
(block
(return_statement
(None) None
)return_statement
)block
)if_statement
(expression_statement
(assignment
(identifier_slug) identifier_slug
(subscript
(identifier_file_path) identifier_file_path
(slice
(call
(identifier_len) identifier_len
(argument_list
(attribute
(identifier_project) identifier_project
(identifier_source_directory) identifier_source_directory
)attribute
)argument_list
)call
(colon) colon
)slice
)subscript
)assignment
)expression_statement
(expression_statement
(assignment
(identifier_url) identifier_url
(call
(attribute
(call
(attribute
(call
(attribute
(string_'/{}') string_'/{}'
(line_continuation_\) line_continuation_\
(identifier_format) identifier_format
)attribute
(argument_list
(identifier_slug) identifier_slug
)argument_list
)call
(line_continuation_\) line_continuation_\
(identifier_replace) identifier_replace
)attribute
(argument_list
(string_'\\') string_'\\'
(string_'/') string_'/'
)argument_list
)call
(line_continuation_\) line_continuation_\
(identifier_replace) identifier_replace
)attribute
(argument_list
(string_'//') string_'//'
(string_'/') string_'/'
)argument_list
)call
)assignment
)expression_statement
(return_statement
(call
(identifier_WEB_INCLUDE) identifier_WEB_INCLUDE
(argument_list
(keyword_argument
(identifier_name) identifier_name
(call
(attribute
(string_':project:{}') string_':project:{}'
(identifier_format) identifier_format
)attribute
(argument_list
(identifier_url) identifier_url
)argument_list
)call
)keyword_argument
(keyword_argument
(identifier_src) identifier_src
(identifier_url) identifier_url
)keyword_argument
)argument_list
)call
)return_statement
)block
)function_definition
)module | Converts the given file_path into a WEB_INCLUDE instance that represents
the deployed version of this file to be loaded into the results project
page
:param project:
Project in which the file_path resides
:param file_path:
Absolute path to the source file for which the WEB_INCLUDE instance
will be created
:return:
The WEB_INCLUDE instance that represents the given source file |
(module
(function_definition
(function_name_register_on_snapshot_deleted) function_name_register_on_snapshot_deleted
(parameters
(identifier_self) identifier_self
(identifier_callback) identifier_callback
)parameters
(block
(expression_statement
(assignment
(identifier_event_type) identifier_event_type
(attribute
(attribute
(identifier_library) identifier_library
(identifier_VBoxEventType) identifier_VBoxEventType
)attribute
(identifier_on_snapshot_deleted) identifier_on_snapshot_deleted
)attribute
)assignment
)expression_statement
(return_statement
(call
(attribute
(attribute
(identifier_self) identifier_self
(identifier_event_source) identifier_event_source
)attribute
(identifier_register_callback) identifier_register_callback
)attribute
(argument_list
(identifier_callback) identifier_callback
(identifier_event_type) identifier_event_type
)argument_list
)call
)return_statement
)block
)function_definition
)module | Set the callback function to consume on snapshot deleted events.
Callback receives a ISnapshotDeletedEvent object.
Returns the callback_id |
(module
(function_definition
(function_name_to_binary) function_name_to_binary
(parameters
(identifier_value) identifier_value
(default_parameter
(identifier_encoding) identifier_encoding
(string_'utf-8') string_'utf-8'
)default_parameter
)parameters
(block
(if_statement
(not_operator
(identifier_value) identifier_value
)not_operator
(block
(return_statement
(string_b'') string_b''
)return_statement
)block
)if_statement
(if_statement
(call
(identifier_isinstance) identifier_isinstance
(argument_list
(identifier_value) identifier_value
(attribute
(identifier_six) identifier_six
(identifier_binary_type) identifier_binary_type
)attribute
)argument_list
)call
(block
(return_statement
(identifier_value) identifier_value
)return_statement
)block
)if_statement
(if_statement
(call
(identifier_isinstance) identifier_isinstance
(argument_list
(identifier_value) identifier_value
(attribute
(identifier_six) identifier_six
(identifier_text_type) identifier_text_type
)attribute
)argument_list
)call
(block
(return_statement
(call
(attribute
(identifier_value) identifier_value
(identifier_encode) identifier_encode
)attribute
(argument_list
(identifier_encoding) identifier_encoding
)argument_list
)call
)return_statement
)block
)if_statement
(return_statement
(call
(attribute
(call
(identifier_to_text) identifier_to_text
(argument_list
(identifier_value) identifier_value
)argument_list
)call
(identifier_encode) identifier_encode
)attribute
(argument_list
(identifier_encoding) identifier_encoding
)argument_list
)call
)return_statement
)block
)function_definition
)module | Convert value to binary string, default encoding is utf-8
:param value: Value to be converted
:param encoding: Desired encoding |
(module
(function_definition
(function_name_check_aggregate) function_name_check_aggregate
(parameters
(identifier_df) identifier_df
(identifier_variable) identifier_variable
(default_parameter
(identifier_components) identifier_components
(None) None
)default_parameter
(default_parameter
(identifier_exclude_on_fail) identifier_exclude_on_fail
(False) False
)default_parameter
(default_parameter
(identifier_multiplier) identifier_multiplier
(integer_1) integer_1
)default_parameter
(dictionary_splat_pattern
(identifier_kwargs) identifier_kwargs
)dictionary_splat_pattern
)parameters
(block
(expression_statement
(assignment
(identifier_fdf) identifier_fdf
(call
(attribute
(identifier_df) identifier_df
(identifier_filter) identifier_filter
)attribute
(argument_list
(dictionary_splat
(identifier_kwargs) identifier_kwargs
)dictionary_splat
)argument_list
)call
)assignment
)expression_statement
(if_statement
(comparison_operator
(call
(identifier_len) identifier_len
(argument_list
(attribute
(identifier_fdf) identifier_fdf
(identifier_data) identifier_data
)attribute
)argument_list
)call
(integer_0) integer_0
)comparison_operator
(block
(expression_statement
(assignment
(identifier_vdf) identifier_vdf
(call
(attribute
(identifier_fdf) identifier_fdf
(identifier_check_aggregate) identifier_check_aggregate
)attribute
(argument_list
(keyword_argument
(identifier_variable) identifier_variable
(identifier_variable) identifier_variable
)keyword_argument
(keyword_argument
(identifier_components) identifier_components
(identifier_components) identifier_components
)keyword_argument
(keyword_argument
(identifier_exclude_on_fail) identifier_exclude_on_fail
(identifier_exclude_on_fail) identifier_exclude_on_fail
)keyword_argument
(keyword_argument
(identifier_multiplier) identifier_multiplier
(identifier_multiplier) identifier_multiplier
)keyword_argument
)argument_list
)call
)assignment
)expression_statement
(expression_statement
(augmented_assignment
(subscript
(attribute
(identifier_df) identifier_df
(identifier_meta) identifier_meta
)attribute
(string_'exclude') string_'exclude'
)subscript
(subscript
(attribute
(identifier_fdf) identifier_fdf
(identifier_meta) identifier_meta
)attribute
(string_'exclude') string_'exclude'
)subscript
)augmented_assignment
)expression_statement
(return_statement
(identifier_vdf) identifier_vdf
)return_statement
)block
)if_statement
)block
)function_definition
)module | Check whether the timeseries values match the aggregation
of sub-categories
Parameters
----------
df: IamDataFrame instance
args: see IamDataFrame.check_aggregate() for details
kwargs: passed to `df.filter()` |
(module
(function_definition
(function_name_spin_sz) function_name_spin_sz
(parameters
(identifier_self) identifier_self
)parameters
(block
(return_statement
(call
(attribute
(identifier_conversions) identifier_conversions
(identifier_secondary_spin) identifier_secondary_spin
)attribute
(argument_list
(attribute
(identifier_self) identifier_self
(identifier_mass1) identifier_mass1
)attribute
(attribute
(identifier_self) identifier_self
(identifier_mass2) identifier_mass2
)attribute
(attribute
(identifier_self) identifier_self
(identifier_spin1z) identifier_spin1z
)attribute
(attribute
(identifier_self) identifier_self
(identifier_spin2z) identifier_spin2z
)attribute
)argument_list
)call
)return_statement
)block
)function_definition
)module | Returns the z-component of the spin of the secondary mass. |
(module
(function_definition
(function_name_validate) function_name_validate
(parameters
(identifier_method) identifier_method
)parameters
(block
(decorated_definition
(decorator
(call
(identifier_wraps) identifier_wraps
(argument_list
(identifier_method) identifier_method
)argument_list
)call
)decorator
(function_definition
(function_name_mod_run) function_name_mod_run
(parameters
(identifier_self) identifier_self
(identifier_rinput) identifier_rinput
)parameters
(block
(expression_statement
(call
(attribute
(identifier_self) identifier_self
(identifier_validate_input) identifier_validate_input
)attribute
(argument_list
(identifier_rinput) identifier_rinput
)argument_list
)call
)expression_statement
(expression_statement
(assignment
(identifier_result) identifier_result
(call
(identifier_method) identifier_method
(argument_list
(identifier_self) identifier_self
(identifier_rinput) identifier_rinput
)argument_list
)call
)assignment
)expression_statement
(expression_statement
(call
(attribute
(identifier_self) identifier_self
(identifier_validate_result) identifier_validate_result
)attribute
(argument_list
(identifier_result) identifier_result
)argument_list
)call
)expression_statement
(return_statement
(identifier_result) identifier_result
)return_statement
)block
)function_definition
)decorated_definition
(return_statement
(identifier_mod_run) identifier_mod_run
)return_statement
)block
)function_definition
)module | Decorate run method, inputs and outputs are validated |
(module
(function_definition
(function_name_process_commission) function_name_process_commission
(parameters
(identifier_self) identifier_self
(identifier_commission) identifier_commission
)parameters
(block
(expression_statement
(assignment
(identifier_asset) identifier_asset
(subscript
(identifier_commission) identifier_commission
(string_'asset') string_'asset'
)subscript
)assignment
)expression_statement
(expression_statement
(assignment
(identifier_cost) identifier_cost
(subscript
(identifier_commission) identifier_commission
(string_'cost') string_'cost'
)subscript
)assignment
)expression_statement
(expression_statement
(call
(attribute
(attribute
(identifier_self) identifier_self
(identifier_position_tracker) identifier_position_tracker
)attribute
(identifier_handle_commission) identifier_handle_commission
)attribute
(argument_list
(identifier_asset) identifier_asset
(identifier_cost) identifier_cost
)argument_list
)call
)expression_statement
(expression_statement
(call
(attribute
(identifier_self) identifier_self
(identifier__cash_flow) identifier__cash_flow
)attribute
(argument_list
(unary_operator
(identifier_cost) identifier_cost
)unary_operator
)argument_list
)call
)expression_statement
)block
)function_definition
)module | Process the commission.
Parameters
----------
commission : zp.Event
The commission being paid. |
(module
(function_definition
(function_name_error) function_name_error
(parameters
(identifier_self) identifier_self
(identifier_msgid) identifier_msgid
(identifier_error) identifier_error
)parameters
(block
(expression_statement
(call
(attribute
(subscript
(attribute
(identifier_self) identifier_self
(identifier_requests) identifier_requests
)attribute
(identifier_msgid) identifier_msgid
)subscript
(identifier_errback) identifier_errback
)attribute
(argument_list
(identifier_error) identifier_error
)argument_list
)call
)expression_statement
(delete_statement
(subscript
(attribute
(identifier_self) identifier_self
(identifier_requests) identifier_requests
)attribute
(identifier_msgid) identifier_msgid
)subscript
)delete_statement
)block
)function_definition
)module | Handle a error message. |
(module
(function_definition
(function_name_fuse_wheels) function_name_fuse_wheels
(parameters
(identifier_to_wheel) identifier_to_wheel
(identifier_from_wheel) identifier_from_wheel
(identifier_out_wheel) identifier_out_wheel
)parameters
(block
(expression_statement
(assignment
(pattern_list
(identifier_to_wheel) identifier_to_wheel
(identifier_from_wheel) identifier_from_wheel
(identifier_out_wheel) identifier_out_wheel
)pattern_list
(list_comprehension
(call
(identifier_abspath) identifier_abspath
(argument_list
(identifier_w) identifier_w
)argument_list
)call
(for_in_clause
(identifier_w) identifier_w
(tuple
(identifier_to_wheel) identifier_to_wheel
(identifier_from_wheel) identifier_from_wheel
(identifier_out_wheel) identifier_out_wheel
)tuple
)for_in_clause
)list_comprehension
)assignment
)expression_statement
(with_statement
(with_clause
(with_item
(call
(identifier_InTemporaryDirectory) identifier_InTemporaryDirectory
(argument_list
)argument_list
)call
)with_item
)with_clause
(block
(expression_statement
(call
(identifier_zip2dir) identifier_zip2dir
(argument_list
(identifier_to_wheel) identifier_to_wheel
(string_'to_wheel') string_'to_wheel'
)argument_list
)call
)expression_statement
(expression_statement
(call
(identifier_zip2dir) identifier_zip2dir
(argument_list
(identifier_from_wheel) identifier_from_wheel
(string_'from_wheel') string_'from_wheel'
)argument_list
)call
)expression_statement
(expression_statement
(call
(identifier_fuse_trees) identifier_fuse_trees
(argument_list
(string_'to_wheel') string_'to_wheel'
(string_'from_wheel') string_'from_wheel'
)argument_list
)call
)expression_statement
(expression_statement
(call
(identifier_rewrite_record) identifier_rewrite_record
(argument_list
(string_'to_wheel') string_'to_wheel'
)argument_list
)call
)expression_statement
(expression_statement
(call
(identifier_dir2zip) identifier_dir2zip
(argument_list
(string_'to_wheel') string_'to_wheel'
(identifier_out_wheel) identifier_out_wheel
)argument_list
)call
)expression_statement
)block
)with_statement
)block
)function_definition
)module | Fuse `from_wheel` into `to_wheel`, write to `out_wheel`
Parameters
---------
to_wheel : str
filename of wheel to fuse into
from_wheel : str
filename of wheel to fuse from
out_wheel : str
filename of new wheel from fusion of `to_wheel` and `from_wheel` |
(module
(function_definition
(function_name_get_server_url) function_name_get_server_url
(parameters
(identifier_self) identifier_self
)parameters
(block
(expression_statement
(assignment
(identifier_server_host) identifier_server_host
(call
(attribute
(attribute
(attribute
(identifier_self) identifier_self
(identifier_driver_wrapper) identifier_driver_wrapper
)attribute
(identifier_config) identifier_config
)attribute
(identifier_get) identifier_get
)attribute
(argument_list
(string_'Server') string_'Server'
(string_'host') string_'host'
)argument_list
)call
)assignment
)expression_statement
(expression_statement
(assignment
(identifier_server_port) identifier_server_port
(call
(attribute
(attribute
(attribute
(identifier_self) identifier_self
(identifier_driver_wrapper) identifier_driver_wrapper
)attribute
(identifier_config) identifier_config
)attribute
(identifier_get) identifier_get
)attribute
(argument_list
(string_'Server') string_'Server'
(string_'port') string_'port'
)argument_list
)call
)assignment
)expression_statement
(expression_statement
(assignment
(identifier_server_username) identifier_server_username
(call
(attribute
(attribute
(attribute
(identifier_self) identifier_self
(identifier_driver_wrapper) identifier_driver_wrapper
)attribute
(identifier_config) identifier_config
)attribute
(identifier_get_optional) identifier_get_optional
)attribute
(argument_list
(string_'Server') string_'Server'
(string_'username') string_'username'
)argument_list
)call
)assignment
)expression_statement
(expression_statement
(assignment
(identifier_server_password) identifier_server_password
(call
(attribute
(attribute
(attribute
(identifier_self) identifier_self
(identifier_driver_wrapper) identifier_driver_wrapper
)attribute
(identifier_config) identifier_config
)attribute
(identifier_get_optional) identifier_get_optional
)attribute
(argument_list
(string_'Server') string_'Server'
(string_'password') string_'password'
)argument_list
)call
)assignment
)expression_statement
(expression_statement
(assignment
(identifier_server_auth) identifier_server_auth
(conditional_expression
(call
(attribute
(string_'{}:{}@') string_'{}:{}@'
(identifier_format) identifier_format
)attribute
(argument_list
(identifier_server_username) identifier_server_username
(identifier_server_password) identifier_server_password
)argument_list
)call
(boolean_operator
(identifier_server_username) identifier_server_username
(identifier_server_password) identifier_server_password
)boolean_operator
(string_'') string_''
)conditional_expression
)assignment
)expression_statement
(expression_statement
(assignment
(identifier_server_url) identifier_server_url
(call
(attribute
(string_'http://{}{}:{}') string_'http://{}{}:{}'
(identifier_format) identifier_format
)attribute
(argument_list
(identifier_server_auth) identifier_server_auth
(identifier_server_host) identifier_server_host
(identifier_server_port) identifier_server_port
)argument_list
)call
)assignment
)expression_statement
(return_statement
(identifier_server_url) identifier_server_url
)return_statement
)block
)function_definition
)module | Return the configured server url
:returns: server url |
(module
(function_definition
(function_name_duplicates) function_name_duplicates
(parameters
(identifier_inlist) identifier_inlist
)parameters
(block
(expression_statement
(assignment
(identifier_dups) identifier_dups
(list
)list
)assignment
)expression_statement
(for_statement
(identifier_i) identifier_i
(call
(identifier_range) identifier_range
(argument_list
(call
(identifier_len) identifier_len
(argument_list
(identifier_inlist) identifier_inlist
)argument_list
)call
)argument_list
)call
(block
(if_statement
(comparison_operator
(subscript
(identifier_inlist) identifier_inlist
(identifier_i) identifier_i
)subscript
(subscript
(identifier_inlist) identifier_inlist
(slice
(binary_operator
(identifier_i) identifier_i
(integer_1) integer_1
)binary_operator
(colon) colon
)slice
)subscript
)comparison_operator
(block
(expression_statement
(call
(attribute
(identifier_dups) identifier_dups
(identifier_append) identifier_append
)attribute
(argument_list
(subscript
(identifier_inlist) identifier_inlist
(identifier_i) identifier_i
)subscript
)argument_list
)call
)expression_statement
)block
)if_statement
)block
)for_statement
(return_statement
(identifier_dups) identifier_dups
)return_statement
)block
)function_definition
)module | Returns duplicate items in the FIRST dimension of the passed list.
Usage: duplicates (inlist) |
(module
(function_definition
(function_name_loads) function_name_loads
(parameters
(identifier_string) identifier_string
)parameters
(block
(expression_statement
(assignment
(identifier_d) identifier_d
(call
(identifier__loads) identifier__loads
(argument_list
(identifier_string) identifier_string
)argument_list
)call
)assignment
)expression_statement
(for_statement
(pattern_list
(identifier_k) identifier_k
(identifier_v) identifier_v
)pattern_list
(call
(attribute
(identifier_d) identifier_d
(identifier_items) identifier_items
)attribute
(argument_list
)argument_list
)call
(block
(expression_statement
(assignment
(subscript
(identifier_FILTERS) identifier_FILTERS
(boolean_operator
(call
(attribute
(identifier_dr) identifier_dr
(identifier_get_component) identifier_get_component
)attribute
(argument_list
(identifier_k) identifier_k
)argument_list
)call
(identifier_k) identifier_k
)boolean_operator
)subscript
(call
(identifier_set) identifier_set
(argument_list
(identifier_v) identifier_v
)argument_list
)call
)assignment
)expression_statement
)block
)for_statement
)block
)function_definition
)module | Loads the filters dictionary given a string. |
(module
(function_definition
(function_name__export_module_attachments) function_name__export_module_attachments
(parameters
(identifier_meta_graph) identifier_meta_graph
)parameters
(block
(expression_statement
(assignment
(identifier_added_attachments) identifier_added_attachments
(call
(attribute
(identifier_tf_v1) identifier_tf_v1
(identifier_get_collection) identifier_get_collection
)attribute
(argument_list
(identifier__ATTACHMENT_COLLECTION_INTERNAL) identifier__ATTACHMENT_COLLECTION_INTERNAL
)argument_list
)call
)assignment
)expression_statement
(if_statement
(not_operator
(identifier_added_attachments) identifier_added_attachments
)not_operator
(block
(return_statement
)return_statement
)block
)if_statement
(expression_statement
(assignment
(identifier_unique_attachments) identifier_unique_attachments
(call
(attribute
(identifier_collections) identifier_collections
(identifier_OrderedDict) identifier_OrderedDict
)attribute
(generator_expression
(tuple
(attribute
(identifier_attachment) identifier_attachment
(identifier_key) identifier_key
)attribute
(identifier_attachment) identifier_attachment
)tuple
(for_in_clause
(identifier_attachment) identifier_attachment
(identifier_added_attachments) identifier_added_attachments
)for_in_clause
)generator_expression
)call
)assignment
)expression_statement
(expression_statement
(assignment
(subscript
(attribute
(attribute
(subscript
(attribute
(identifier_meta_graph) identifier_meta_graph
(identifier_collection_def) identifier_collection_def
)attribute
(identifier_ATTACHMENT_COLLECTION_SAVED) identifier_ATTACHMENT_COLLECTION_SAVED
)subscript
(identifier_bytes_list) identifier_bytes_list
)attribute
(identifier_value) identifier_value
)attribute
(slice
(colon) colon
)slice
)subscript
(list_comprehension
(call
(attribute
(identifier_attachment) identifier_attachment
(identifier_SerializeToString) identifier_SerializeToString
)attribute
(argument_list
)argument_list
)call
(for_in_clause
(identifier_attachment) identifier_attachment
(call
(attribute
(identifier_unique_attachments) identifier_unique_attachments
(identifier_values) identifier_values
)attribute
(argument_list
)argument_list
)call
)for_in_clause
)list_comprehension
)assignment
)expression_statement
)block
)function_definition
)module | Exports ModuleAttachments from the current tf.Graph into `meta_graph`. |
(module
(function_definition
(function_name_js_adaptor) function_name_js_adaptor
(parameters
(identifier_buffer) identifier_buffer
)parameters
(block
(expression_statement
(assignment
(identifier_buffer) identifier_buffer
(call
(attribute
(identifier_re) identifier_re
(identifier_sub) identifier_sub
)attribute
(argument_list
(string_'true') string_'true'
(string_'True') string_'True'
(identifier_buffer) identifier_buffer
)argument_list
)call
)assignment
)expression_statement
(expression_statement
(assignment
(identifier_buffer) identifier_buffer
(call
(attribute
(identifier_re) identifier_re
(identifier_sub) identifier_sub
)attribute
(argument_list
(string_'false') string_'false'
(string_'False') string_'False'
(identifier_buffer) identifier_buffer
)argument_list
)call
)assignment
)expression_statement
(expression_statement
(assignment
(identifier_buffer) identifier_buffer
(call
(attribute
(identifier_re) identifier_re
(identifier_sub) identifier_sub
)attribute
(argument_list
(string_'none') string_'none'
(string_'None') string_'None'
(identifier_buffer) identifier_buffer
)argument_list
)call
)assignment
)expression_statement
(expression_statement
(assignment
(identifier_buffer) identifier_buffer
(call
(attribute
(identifier_re) identifier_re
(identifier_sub) identifier_sub
)attribute
(argument_list
(string_'NaN') string_'NaN'
(string_'"NaN"') string_'"NaN"'
(identifier_buffer) identifier_buffer
)argument_list
)call
)assignment
)expression_statement
(return_statement
(identifier_buffer) identifier_buffer
)return_statement
)block
)function_definition
)module | convert javascript objects like true, none, NaN etc. to
quoted word.
Arguments:
buffer: string to be converted
Returns:
string after conversion |
(module
(function_definition
(function_name_is_article) function_name_is_article
(parameters
(identifier_self) identifier_self
(identifier_response) identifier_response
(identifier_url) identifier_url
)parameters
(block
(expression_statement
(assignment
(identifier_site) identifier_site
(subscript
(attribute
(identifier_self) identifier_self
(identifier___sites_object) identifier___sites_object
)attribute
(identifier_url) identifier_url
)subscript
)assignment
)expression_statement
(expression_statement
(assignment
(identifier_heuristics) identifier_heuristics
(call
(attribute
(identifier_self) identifier_self
(identifier___get_enabled_heuristics) identifier___get_enabled_heuristics
)attribute
(argument_list
(identifier_url) identifier_url
)argument_list
)call
)assignment
)expression_statement
(expression_statement
(call
(attribute
(attribute
(identifier_self) identifier_self
(identifier_log) identifier_log
)attribute
(identifier_info) identifier_info
)attribute
(argument_list
(string_"Checking site: %s") string_"Checking site: %s"
(attribute
(identifier_response) identifier_response
(identifier_url) identifier_url
)attribute
)argument_list
)call
)expression_statement
(expression_statement
(assignment
(identifier_statement) identifier_statement
(call
(attribute
(identifier_self) identifier_self
(identifier___get_condition) identifier___get_condition
)attribute
(argument_list
(identifier_url) identifier_url
)argument_list
)call
)assignment
)expression_statement
(expression_statement
(call
(attribute
(attribute
(identifier_self) identifier_self
(identifier_log) identifier_log
)attribute
(identifier_debug) identifier_debug
)attribute
(argument_list
(string_"Condition (original): %s") string_"Condition (original): %s"
(identifier_statement) identifier_statement
)argument_list
)call
)expression_statement
(for_statement
(pattern_list
(identifier_heuristic) identifier_heuristic
(identifier_condition) identifier_condition
)pattern_list
(call
(attribute
(identifier_heuristics) identifier_heuristics
(identifier_items) identifier_items
)attribute
(argument_list
)argument_list
)call
(block
(expression_statement
(assignment
(identifier_heuristic_func) identifier_heuristic_func
(call
(identifier_getattr) identifier_getattr
(argument_list
(identifier_self) identifier_self
(identifier_heuristic) identifier_heuristic
)argument_list
)call
)assignment
)expression_statement
(expression_statement
(assignment
(identifier_result) identifier_result
(call
(identifier_heuristic_func) identifier_heuristic_func
(argument_list
(identifier_response) identifier_response
(identifier_site) identifier_site
)argument_list
)call
)assignment
)expression_statement
(expression_statement
(assignment
(identifier_check) identifier_check
(call
(attribute
(identifier_self) identifier_self
(identifier___evaluate_result) identifier___evaluate_result
)attribute
(argument_list
(identifier_result) identifier_result
(identifier_condition) identifier_condition
)argument_list
)call
)assignment
)expression_statement
(expression_statement
(assignment
(identifier_statement) identifier_statement
(call
(attribute
(identifier_re) identifier_re
(identifier_sub) identifier_sub
)attribute
(argument_list
(binary_operator
(string_r"\b%s\b") string_r"\b%s\b"
(identifier_heuristic) identifier_heuristic
)binary_operator
(call
(identifier_str) identifier_str
(argument_list
(identifier_check) identifier_check
)argument_list
)call
(identifier_statement) identifier_statement
)argument_list
)call
)assignment
)expression_statement
(expression_statement
(call
(attribute
(attribute
(identifier_self) identifier_self
(identifier_log) identifier_log
)attribute
(identifier_debug) identifier_debug
)attribute
(argument_list
(concatenated_string
(string_"Checking heuristic (%s)") string_"Checking heuristic (%s)"
(string_" result (%s) on condition (%s): %s") string_" result (%s) on condition (%s): %s"
)concatenated_string
(identifier_heuristic) identifier_heuristic
(identifier_result) identifier_result
(identifier_condition) identifier_condition
(identifier_check) identifier_check
)argument_list
)call
)expression_statement
)block
)for_statement
(expression_statement
(call
(attribute
(attribute
(identifier_self) identifier_self
(identifier_log) identifier_log
)attribute
(identifier_debug) identifier_debug
)attribute
(argument_list
(string_"Condition (evaluated): %s") string_"Condition (evaluated): %s"
(identifier_statement) identifier_statement
)argument_list
)call
)expression_statement
(expression_statement
(assignment
(identifier_is_article) identifier_is_article
(call
(identifier_eval) identifier_eval
(argument_list
(identifier_statement) identifier_statement
)argument_list
)call
)assignment
)expression_statement
(expression_statement
(call
(attribute
(attribute
(identifier_self) identifier_self
(identifier_log) identifier_log
)attribute
(identifier_debug) identifier_debug
)attribute
(argument_list
(string_"Article accepted: %s") string_"Article accepted: %s"
(identifier_is_article) identifier_is_article
)argument_list
)call
)expression_statement
(return_statement
(identifier_is_article) identifier_is_article
)return_statement
)block
)function_definition
)module | Tests if the given response is an article by calling and checking
the heuristics set in config.cfg and sitelist.json
:param obj response: The response of the site.
:param str url: The base_url (needed to get the site-specific config
from the JSON-file)
:return bool: true if the heuristics match the site as an article |
(module
(function_definition
(function_name_select) function_name_select
(parameters
(typed_parameter
(list_splat_pattern
(identifier_signals) identifier_signals
)list_splat_pattern
(type
(identifier_Signal) identifier_Signal
)type
)typed_parameter
(dictionary_splat_pattern
(identifier_kwargs) identifier_kwargs
)dictionary_splat_pattern
)parameters
(type
(generic_type
(identifier_List) identifier_List
(type_parameter
(type
(identifier_Signal) identifier_Signal
)type
)type_parameter
)generic_type
)type
(block
(class_definition
(identifier_CleanUp) identifier_CleanUp
(argument_list
(identifier_Interrupt) identifier_Interrupt
)argument_list
(block
(pass_statement
)pass_statement
)block
)class_definition
(expression_statement
(assignment
(identifier_timeout) identifier_timeout
(call
(attribute
(identifier_kwargs) identifier_kwargs
(identifier_get) identifier_get
)attribute
(argument_list
(string_"timeout") string_"timeout"
(None) None
)argument_list
)call
)assignment
)expression_statement
(if_statement
(not_operator
(call
(identifier_isinstance) identifier_isinstance
(argument_list
(identifier_timeout) identifier_timeout
(tuple
(identifier_float) identifier_float
(identifier_int) identifier_int
(call
(identifier_type) identifier_type
(argument_list
(None) None
)argument_list
)call
)tuple
)argument_list
)call
)not_operator
(block
(raise_statement
(call
(identifier_ValueError) identifier_ValueError
(argument_list
(string_"The timeout keyword parameter can be either None or a number.") string_"The timeout keyword parameter can be either None or a number."
)argument_list
)call
)raise_statement
)block
)if_statement
(function_definition
(function_name_wait_one) function_name_wait_one
(parameters
(typed_parameter
(identifier_signal) identifier_signal
(type
(identifier_Signal) identifier_Signal
)type
)typed_parameter
(typed_parameter
(identifier_common) identifier_common
(type
(identifier_Signal) identifier_Signal
)type
)typed_parameter
)parameters
(type
(None) None
)type
(block
(try_statement
(block
(expression_statement
(call
(attribute
(identifier_signal) identifier_signal
(identifier_wait) identifier_wait
)attribute
(argument_list
)argument_list
)call
)expression_statement
(expression_statement
(call
(attribute
(identifier_common) identifier_common
(identifier_turn_on) identifier_turn_on
)attribute
(argument_list
)argument_list
)call
)expression_statement
)block
(except_clause
(identifier_CleanUp) identifier_CleanUp
(block
(pass_statement
)pass_statement
)block
)except_clause
)try_statement
)block
)function_definition
(expression_statement
(assignment
(identifier_common) identifier_common
(call
(attribute
(call
(identifier_Signal) identifier_Signal
(argument_list
(keyword_argument
(identifier_name) identifier_name
(binary_operator
(attribute
(identifier_local) identifier_local
(identifier_name) identifier_name
)attribute
(string_"-selector") string_"-selector"
)binary_operator
)keyword_argument
)argument_list
)call
(identifier_turn_off) identifier_turn_off
)attribute
(argument_list
)argument_list
)call
)assignment
)expression_statement
(if_statement
(comparison_operator
(identifier__logger) identifier__logger
(None) None
)comparison_operator
(block
(expression_statement
(call
(identifier__log) identifier__log
(argument_list
(identifier_INFO) identifier_INFO
(string_"select") string_"select"
(string_"select") string_"select"
(string_"select") string_"select"
(keyword_argument
(identifier_signals) identifier_signals
(list_comprehension
(attribute
(identifier_sig) identifier_sig
(identifier_name) identifier_name
)attribute
(for_in_clause
(identifier_sig) identifier_sig
(identifier_signals) identifier_signals
)for_in_clause
)list_comprehension
)keyword_argument
)argument_list
)call
)expression_statement
)block
)if_statement
(expression_statement
(assignment
(identifier_procs) identifier_procs
(list
)list
)assignment
)expression_statement
(for_statement
(identifier_signal) identifier_signal
(identifier_signals) identifier_signals
(block
(expression_statement
(call
(attribute
(identifier_procs) identifier_procs
(identifier_append) identifier_append
)attribute
(argument_list
(call
(identifier_add) identifier_add
(argument_list
(identifier_wait_one) identifier_wait_one
(identifier_signal) identifier_signal
(identifier_common) identifier_common
)argument_list
)call
)argument_list
)call
)expression_statement
)block
)for_statement
(try_statement
(block
(expression_statement
(call
(attribute
(identifier_common) identifier_common
(identifier_wait) identifier_wait
)attribute
(argument_list
(identifier_timeout) identifier_timeout
)argument_list
)call
)expression_statement
)block
(finally_clause
(block
(for_statement
(identifier_proc) identifier_proc
(identifier_procs) identifier_procs
(block
(expression_statement
(call
(attribute
(identifier_proc) identifier_proc
(identifier_interrupt) identifier_interrupt
)attribute
(argument_list
(call
(identifier_CleanUp) identifier_CleanUp
(argument_list
)argument_list
)call
)argument_list
)call
)expression_statement
)block
)for_statement
)block
)finally_clause
)try_statement
(return_statement
(list_comprehension
(identifier_signal) identifier_signal
(for_in_clause
(identifier_signal) identifier_signal
(identifier_signals) identifier_signals
)for_in_clause
(if_clause
(attribute
(identifier_signal) identifier_signal
(identifier_is_on) identifier_is_on
)attribute
)if_clause
)list_comprehension
)return_statement
)block
)function_definition
)module | Allows the current process to wait for multiple concurrent signals. Waits until one of the signals turns on, at
which point this signal is returned.
:param timeout:
If this parameter is not ``None``, it is taken as a delay at the end of which the process times out, and
stops waiting on the set of :py:class:`Signal`s. In such a situation, a :py:class:`Timeout` exception is raised
on the process. |
(module
(function_definition
(function_name__update) function_name__update
(parameters
(identifier_self) identifier_self
(identifier_dataFile) identifier_dataFile
(identifier_handle) identifier_handle
)parameters
(block
(expression_statement
(call
(attribute
(attribute
(identifier_self) identifier_self
(identifier__cache) identifier__cache
)attribute
(identifier_remove) identifier_remove
)attribute
(argument_list
(tuple
(identifier_dataFile) identifier_dataFile
(identifier_handle) identifier_handle
)tuple
)argument_list
)call
)expression_statement
(expression_statement
(call
(attribute
(identifier_self) identifier_self
(identifier__add) identifier__add
)attribute
(argument_list
(identifier_dataFile) identifier_dataFile
(identifier_handle) identifier_handle
)argument_list
)call
)expression_statement
)block
)function_definition
)module | Update the priority of the file handle. The element is first
removed and then added to the left of the deque. |
(module
(function_definition
(function_name_create_divisao_dc) function_name_create_divisao_dc
(parameters
(identifier_self) identifier_self
)parameters
(block
(return_statement
(call
(identifier_DivisaoDc) identifier_DivisaoDc
(argument_list
(attribute
(identifier_self) identifier_self
(identifier_networkapi_url) identifier_networkapi_url
)attribute
(attribute
(identifier_self) identifier_self
(identifier_user) identifier_user
)attribute
(attribute
(identifier_self) identifier_self
(identifier_password) identifier_password
)attribute
(attribute
(identifier_self) identifier_self
(identifier_user_ldap) identifier_user_ldap
)attribute
)argument_list
)call
)return_statement
)block
)function_definition
)module | Get an instance of divisao_dc services facade. |
(module
(function_definition
(function_name_global_state_code) function_name_global_state_code
(parameters
(identifier_self) identifier_self
)parameters
(block
(expression_statement
(call
(attribute
(identifier_self) identifier_self
(identifier__generate_func_code) identifier__generate_func_code
)attribute
(argument_list
)argument_list
)call
)expression_statement
(if_statement
(not_operator
(attribute
(identifier_self) identifier_self
(identifier__compile_regexps) identifier__compile_regexps
)attribute
)not_operator
(block
(return_statement
(call
(attribute
(string_'\n') string_'\n'
(identifier_join) identifier_join
)attribute
(argument_list
(list
(string_'from fastjsonschema import JsonSchemaException') string_'from fastjsonschema import JsonSchemaException'
(string_'') string_''
(string_'') string_''
)list
)argument_list
)call
)return_statement
)block
)if_statement
(expression_statement
(assignment
(identifier_regexs) identifier_regexs
(list_comprehension
(call
(attribute
(string_'"{}": re.compile(r"{}")') string_'"{}": re.compile(r"{}")'
(identifier_format) identifier_format
)attribute
(argument_list
(identifier_key) identifier_key
(attribute
(identifier_value) identifier_value
(identifier_pattern) identifier_pattern
)attribute
)argument_list
)call
(for_in_clause
(pattern_list
(identifier_key) identifier_key
(identifier_value) identifier_value
)pattern_list
(call
(attribute
(attribute
(identifier_self) identifier_self
(identifier__compile_regexps) identifier__compile_regexps
)attribute
(identifier_items) identifier_items
)attribute
(argument_list
)argument_list
)call
)for_in_clause
)list_comprehension
)assignment
)expression_statement
(return_statement
(call
(attribute
(string_'\n') string_'\n'
(identifier_join) identifier_join
)attribute
(argument_list
(list
(string_'import re') string_'import re'
(string_'from fastjsonschema import JsonSchemaException') string_'from fastjsonschema import JsonSchemaException'
(string_'') string_''
(string_'') string_''
(string_'REGEX_PATTERNS = {') string_'REGEX_PATTERNS = {'
(binary_operator
(string_' ') string_' '
(call
(attribute
(string_',\n ') string_',\n '
(identifier_join) identifier_join
)attribute
(argument_list
(identifier_regexs) identifier_regexs
)argument_list
)call
)binary_operator
(string_'}') string_'}'
(string_'') string_''
)list
)argument_list
)call
)return_statement
)block
)function_definition
)module | Returns global variables for generating function from ``func_code`` as code.
Includes compiled regular expressions and imports. |
(module
(function_definition
(function_name_first) function_name_first
(parameters
(identifier_self) identifier_self
(identifier_values) identifier_values
(default_parameter
(identifier_axis) identifier_axis
(integer_0) integer_0
)default_parameter
)parameters
(block
(expression_statement
(assignment
(identifier_values) identifier_values
(call
(attribute
(identifier_np) identifier_np
(identifier_asarray) identifier_asarray
)attribute
(argument_list
(identifier_values) identifier_values
)argument_list
)call
)assignment
)expression_statement
(return_statement
(expression_list
(attribute
(identifier_self) identifier_self
(identifier_unique) identifier_unique
)attribute
(call
(attribute
(identifier_np) identifier_np
(identifier_take) identifier_take
)attribute
(argument_list
(identifier_values) identifier_values
(subscript
(attribute
(attribute
(identifier_self) identifier_self
(identifier_index) identifier_index
)attribute
(identifier_sorter) identifier_sorter
)attribute
(attribute
(attribute
(identifier_self) identifier_self
(identifier_index) identifier_index
)attribute
(identifier_start) identifier_start
)attribute
)subscript
(identifier_axis) identifier_axis
)argument_list
)call
)expression_list
)return_statement
)block
)function_definition
)module | return values at first occurance of its associated key
Parameters
----------
values : array_like, [keys, ...]
values to pick the first value of per group
axis : int, optional
alternative reduction axis for values
Returns
-------
unique: ndarray, [groups]
unique keys
reduced : ndarray, [groups, ...]
value array, reduced over groups |
(module
(function_definition
(function_name_sunset_utc) function_name_sunset_utc
(parameters
(identifier_self) identifier_self
(identifier_date) identifier_date
(identifier_latitude) identifier_latitude
(identifier_longitude) identifier_longitude
(default_parameter
(identifier_observer_elevation) identifier_observer_elevation
(integer_0) integer_0
)default_parameter
)parameters
(block
(try_statement
(block
(return_statement
(call
(attribute
(identifier_self) identifier_self
(identifier__calc_time) identifier__calc_time
)attribute
(argument_list
(binary_operator
(integer_90) integer_90
(float_0.833) float_0.833
)binary_operator
(identifier_SUN_SETTING) identifier_SUN_SETTING
(identifier_date) identifier_date
(identifier_latitude) identifier_latitude
(identifier_longitude) identifier_longitude
(identifier_observer_elevation) identifier_observer_elevation
)argument_list
)call
)return_statement
)block
(except_clause
(as_pattern
(identifier_ValueError) identifier_ValueError
(as_pattern_target
(identifier_exc) identifier_exc
)as_pattern_target
)as_pattern
(block
(if_statement
(comparison_operator
(subscript
(attribute
(identifier_exc) identifier_exc
(identifier_args) identifier_args
)attribute
(integer_0) integer_0
)subscript
(string_"math domain error") string_"math domain error"
)comparison_operator
(block
(raise_statement
(call
(identifier_AstralError) identifier_AstralError
(argument_list
(parenthesized_expression
(concatenated_string
(string_"Sun never reaches the horizon on this day, ") string_"Sun never reaches the horizon on this day, "
(string_"at this location.") string_"at this location."
)concatenated_string
)parenthesized_expression
)argument_list
)call
)raise_statement
)block
(else_clause
(block
(raise_statement
)raise_statement
)block
)else_clause
)if_statement
)block
)except_clause
)try_statement
)block
)function_definition
)module | Calculate sunset time in the UTC timezone.
:param date: Date to calculate for.
:type date: :class:`datetime.date`
:param latitude: Latitude - Northern latitudes should be positive
:type latitude: float
:param longitude: Longitude - Eastern longitudes should be positive
:type longitude: float
:param observer_elevation: Elevation in metres to calculate sunset for
:type observer_elevation: int
:return: The UTC date and time at which sunset occurs.
:rtype: :class:`~datetime.datetime` |
(module
(function_definition
(function_name_restart) function_name_restart
(parameters
(identifier_self) identifier_self
(default_parameter
(identifier_force) identifier_force
(False) False
)default_parameter
(default_parameter
(identifier_wait_for_available) identifier_wait_for_available
(True) True
)default_parameter
(default_parameter
(identifier_operation_timeout) identifier_operation_timeout
(None) None
)default_parameter
)parameters
(block
(expression_statement
(assignment
(identifier_body) identifier_body
(dictionary
(pair
(string_'force') string_'force'
(identifier_force) identifier_force
)pair
)dictionary
)assignment
)expression_statement
(expression_statement
(call
(attribute
(attribute
(attribute
(identifier_self) identifier_self
(identifier_manager) identifier_manager
)attribute
(identifier_session) identifier_session
)attribute
(identifier_post) identifier_post
)attribute
(argument_list
(binary_operator
(attribute
(identifier_self) identifier_self
(identifier_uri) identifier_uri
)attribute
(string_'/operations/restart') string_'/operations/restart'
)binary_operator
(keyword_argument
(identifier_body) identifier_body
(identifier_body) identifier_body
)keyword_argument
)argument_list
)call
)expression_statement
(if_statement
(identifier_wait_for_available) identifier_wait_for_available
(block
(expression_statement
(call
(attribute
(identifier_time) identifier_time
(identifier_sleep) identifier_sleep
)attribute
(argument_list
(integer_10) integer_10
)argument_list
)call
)expression_statement
(expression_statement
(call
(attribute
(attribute
(attribute
(identifier_self) identifier_self
(identifier_manager) identifier_manager
)attribute
(identifier_client) identifier_client
)attribute
(identifier_wait_for_available) identifier_wait_for_available
)attribute
(argument_list
(keyword_argument
(identifier_operation_timeout) identifier_operation_timeout
(identifier_operation_timeout) identifier_operation_timeout
)keyword_argument
)argument_list
)call
)expression_statement
)block
)if_statement
)block
)function_definition
)module | Restart the HMC represented by this Console object.
Once the HMC is online again, this Console object, as well as any other
resource objects accessed through this HMC, can continue to be used.
An automatic re-logon will be performed under the covers, because the
HMC restart invalidates the currently used HMC session.
Authorization requirements:
* Task permission for the "Shutdown/Restart" task.
* "Remote Restart" must be enabled on the HMC.
Parameters:
force (bool):
Boolean controlling whether the restart operation is processed when
users are connected (`True`) or not (`False`). Users in this sense
are local or remote GUI users. HMC WS API clients do not count as
users for this purpose.
wait_for_available (bool):
Boolean controlling whether this method should wait for the HMC to
become available again after the restart, as follows:
* If `True`, this method will wait until the HMC has restarted and
is available again. The
:meth:`~zhmcclient.Client.query_api_version` method will be used
to check for availability of the HMC.
* If `False`, this method will return immediately once the HMC
has accepted the request to be restarted.
operation_timeout (:term:`number`):
Timeout in seconds, for waiting for HMC availability after the
restart. The special value 0 means that no timeout is set. `None`
means that the default async operation timeout of the session is
used. If the timeout expires when `wait_for_available=True`, a
:exc:`~zhmcclient.OperationTimeout` is raised.
Raises:
:exc:`~zhmcclient.HTTPError`
:exc:`~zhmcclient.ParseError`
:exc:`~zhmcclient.AuthError`
:exc:`~zhmcclient.ConnectionError`
:exc:`~zhmcclient.OperationTimeout`: The timeout expired while
waiting for the HMC to become available again after the restart. |
(module
(function_definition
(function_name_show_agent) function_name_show_agent
(parameters
(identifier_self) identifier_self
(identifier_agent) identifier_agent
(dictionary_splat_pattern
(identifier__params) identifier__params
)dictionary_splat_pattern
)parameters
(block
(return_statement
(call
(attribute
(identifier_self) identifier_self
(identifier_get) identifier_get
)attribute
(argument_list
(binary_operator
(attribute
(identifier_self) identifier_self
(identifier_agent_path) identifier_agent_path
)attribute
(parenthesized_expression
(identifier_agent) identifier_agent
)parenthesized_expression
)binary_operator
(keyword_argument
(identifier_params) identifier_params
(identifier__params) identifier__params
)keyword_argument
)argument_list
)call
)return_statement
)block
)function_definition
)module | Fetches information of a certain agent. |
(module
(function_definition
(function_name___iterate_value) function_name___iterate_value
(parameters
(identifier_self) identifier_self
(identifier_value) identifier_value
)parameters
(block
(if_statement
(boolean_operator
(call
(identifier_hasattr) identifier_hasattr
(argument_list
(identifier_value) identifier_value
(string_'__dict__') string_'__dict__'
)argument_list
)call
(call
(identifier_isinstance) identifier_isinstance
(argument_list
(identifier_value) identifier_value
(identifier_dict) identifier_dict
)argument_list
)call
)boolean_operator
(block
(return_statement
(call
(attribute
(identifier_self) identifier_self
(identifier___find_object_children) identifier___find_object_children
)attribute
(argument_list
(identifier_value) identifier_value
)argument_list
)call
)return_statement
)block
(elif_clause
(call
(identifier_isinstance) identifier_isinstance
(argument_list
(identifier_value) identifier_value
(tuple
(identifier_list) identifier_list
(identifier_tuple) identifier_tuple
(identifier_set) identifier_set
)tuple
)argument_list
)call
(block
(return_statement
(call
(attribute
(identifier_self) identifier_self
(identifier___construct_list) identifier___construct_list
)attribute
(argument_list
(identifier_value) identifier_value
)argument_list
)call
)return_statement
)block
)elif_clause
)if_statement
(return_statement
(call
(attribute
(identifier_self) identifier_self
(identifier_safe_values) identifier_safe_values
)attribute
(argument_list
(identifier_value) identifier_value
)argument_list
)call
)return_statement
)block
)function_definition
)module | Return value for JSON serialization |
(module
(function_definition
(function_name_add_corpus) function_name_add_corpus
(parameters
(identifier_self) identifier_self
(identifier_customization_id) identifier_customization_id
(identifier_corpus_name) identifier_corpus_name
(identifier_corpus_file) identifier_corpus_file
(default_parameter
(identifier_allow_overwrite) identifier_allow_overwrite
(None) None
)default_parameter
(dictionary_splat_pattern
(identifier_kwargs) identifier_kwargs
)dictionary_splat_pattern
)parameters
(block
(if_statement
(comparison_operator
(identifier_customization_id) identifier_customization_id
(None) None
)comparison_operator
(block
(raise_statement
(call
(identifier_ValueError) identifier_ValueError
(argument_list
(string_'customization_id must be provided') string_'customization_id must be provided'
)argument_list
)call
)raise_statement
)block
)if_statement
(if_statement
(comparison_operator
(identifier_corpus_name) identifier_corpus_name
(None) None
)comparison_operator
(block
(raise_statement
(call
(identifier_ValueError) identifier_ValueError
(argument_list
(string_'corpus_name must be provided') string_'corpus_name must be provided'
)argument_list
)call
)raise_statement
)block
)if_statement
(if_statement
(comparison_operator
(identifier_corpus_file) identifier_corpus_file
(None) None
)comparison_operator
(block
(raise_statement
(call
(identifier_ValueError) identifier_ValueError
(argument_list
(string_'corpus_file must be provided') string_'corpus_file must be provided'
)argument_list
)call
)raise_statement
)block
)if_statement
(expression_statement
(assignment
(identifier_headers) identifier_headers
(dictionary
)dictionary
)assignment
)expression_statement
(if_statement
(comparison_operator
(string_'headers') string_'headers'
(identifier_kwargs) identifier_kwargs
)comparison_operator
(block
(expression_statement
(call
(attribute
(identifier_headers) identifier_headers
(identifier_update) identifier_update
)attribute
(argument_list
(call
(attribute
(identifier_kwargs) identifier_kwargs
(identifier_get) identifier_get
)attribute
(argument_list
(string_'headers') string_'headers'
)argument_list
)call
)argument_list
)call
)expression_statement
)block
)if_statement
(expression_statement
(assignment
(identifier_sdk_headers) identifier_sdk_headers
(call
(identifier_get_sdk_headers) identifier_get_sdk_headers
(argument_list
(string_'speech_to_text') string_'speech_to_text'
(string_'V1') string_'V1'
(string_'add_corpus') string_'add_corpus'
)argument_list
)call
)assignment
)expression_statement
(expression_statement
(call
(attribute
(identifier_headers) identifier_headers
(identifier_update) identifier_update
)attribute
(argument_list
(identifier_sdk_headers) identifier_sdk_headers
)argument_list
)call
)expression_statement
(expression_statement
(assignment
(identifier_params) identifier_params
(dictionary
(pair
(string_'allow_overwrite') string_'allow_overwrite'
(identifier_allow_overwrite) identifier_allow_overwrite
)pair
)dictionary
)assignment
)expression_statement
(expression_statement
(assignment
(identifier_form_data) identifier_form_data
(dictionary
)dictionary
)assignment
)expression_statement
(expression_statement
(assignment
(subscript
(identifier_form_data) identifier_form_data
(string_'corpus_file') string_'corpus_file'
)subscript
(tuple
(None) None
(identifier_corpus_file) identifier_corpus_file
(string_'text/plain') string_'text/plain'
)tuple
)assignment
)expression_statement
(expression_statement
(assignment
(identifier_url) identifier_url
(call
(attribute
(string_'/v1/customizations/{0}/corpora/{1}') string_'/v1/customizations/{0}/corpora/{1}'
(identifier_format) identifier_format
)attribute
(argument_list
(list_splat
(call
(attribute
(identifier_self) identifier_self
(identifier__encode_path_vars) identifier__encode_path_vars
)attribute
(argument_list
(identifier_customization_id) identifier_customization_id
(identifier_corpus_name) identifier_corpus_name
)argument_list
)call
)list_splat
)argument_list
)call
)assignment
)expression_statement
(expression_statement
(assignment
(identifier_response) identifier_response
(call
(attribute
(identifier_self) identifier_self
(identifier_request) identifier_request
)attribute
(argument_list
(keyword_argument
(identifier_method) identifier_method
(string_'POST') string_'POST'
)keyword_argument
(keyword_argument
(identifier_url) identifier_url
(identifier_url) identifier_url
)keyword_argument
(keyword_argument
(identifier_headers) identifier_headers
(identifier_headers) identifier_headers
)keyword_argument
(keyword_argument
(identifier_params) identifier_params
(identifier_params) identifier_params
)keyword_argument
(keyword_argument
(identifier_files) identifier_files
(identifier_form_data) identifier_form_data
)keyword_argument
(keyword_argument
(identifier_accept_json) identifier_accept_json
(True) True
)keyword_argument
)argument_list
)call
)assignment
)expression_statement
(return_statement
(identifier_response) identifier_response
)return_statement
)block
)function_definition
)module | Add a corpus.
Adds a single corpus text file of new training data to a custom language model.
Use multiple requests to submit multiple corpus text files. You must use
credentials for the instance of the service that owns a model to add a corpus to
it. Adding a corpus does not affect the custom language model until you train the
model for the new data by using the **Train a custom language model** method.
Submit a plain text file that contains sample sentences from the domain of
interest to enable the service to extract words in context. The more sentences you
add that represent the context in which speakers use words from the domain, the
better the service's recognition accuracy.
The call returns an HTTP 201 response code if the corpus is valid. The service
then asynchronously processes the contents of the corpus and automatically
extracts new words that it finds. This can take on the order of a minute or two to
complete depending on the total number of words and the number of new words in the
corpus, as well as the current load on the service. You cannot submit requests to
add additional resources to the custom model or to train the model until the
service's analysis of the corpus for the current request completes. Use the **List
a corpus** method to check the status of the analysis.
The service auto-populates the model's words resource with words from the corpus
that are not found in its base vocabulary. These are referred to as
out-of-vocabulary (OOV) words. You can use the **List custom words** method to
examine the words resource. You can use other words method to eliminate typos and
modify how words are pronounced as needed.
To add a corpus file that has the same name as an existing corpus, set the
`allow_overwrite` parameter to `true`; otherwise, the request fails. Overwriting
an existing corpus causes the service to process the corpus text file and extract
OOV words anew. Before doing so, it removes any OOV words associated with the
existing corpus from the model's words resource unless they were also added by
another corpus or grammar, or they have been modified in some way with the **Add
custom words** or **Add a custom word** method.
The service limits the overall amount of data that you can add to a custom model
to a maximum of 10 million total words from all sources combined. Also, you can
add no more than 30 thousand custom (OOV) words to a model. This includes words
that the service extracts from corpora and grammars, and words that you add
directly.
**See also:**
* [Working with
corpora](https://cloud.ibm.com/docs/services/speech-to-text/language-resource.html#workingCorpora)
* [Add corpora to the custom language
model](https://cloud.ibm.com/docs/services/speech-to-text/language-create.html#addCorpora).
:param str customization_id: The customization ID (GUID) of the custom language
model that is to be used for the request. You must make the request with
credentials for the instance of the service that owns the custom model.
:param str corpus_name: The name of the new corpus for the custom language model.
Use a localized name that matches the language of the custom model and reflects
the contents of the corpus.
* Include a maximum of 128 characters in the name.
* Do not include spaces, slashes, or backslashes in the name.
* Do not use the name of an existing corpus or grammar that is already defined for
the custom model.
* Do not use the name `user`, which is reserved by the service to denote custom
words that are added or modified by the user.
:param file corpus_file: A plain text file that contains the training data for the
corpus. Encode the file in UTF-8 if it contains non-ASCII characters; the service
assumes UTF-8 encoding if it encounters non-ASCII characters.
Make sure that you know the character encoding of the file. You must use that
encoding when working with the words in the custom language model. For more
information, see [Character
encoding](https://cloud.ibm.com/docs/services/speech-to-text/language-resource.html#charEncoding).
With the `curl` command, use the `--data-binary` option to upload the file for the
request.
:param bool allow_overwrite: If `true`, the specified corpus overwrites an
existing corpus with the same name. If `false`, the request fails if a corpus with
the same name already exists. The parameter has no effect if a corpus with the
same name does not already exist.
:param dict headers: A `dict` containing the request headers
:return: A `DetailedResponse` containing the result, headers and HTTP status code.
:rtype: DetailedResponse |
(module
(function_definition
(function_name_get_cache_buster) function_name_get_cache_buster
(parameters
(identifier_src_path) identifier_src_path
(default_parameter
(identifier_method) identifier_method
(string_'importtime') string_'importtime'
)default_parameter
)parameters
(block
(try_statement
(block
(expression_statement
(assignment
(identifier_fn) identifier_fn
(subscript
(identifier__BUST_METHODS) identifier__BUST_METHODS
(identifier_method) identifier_method
)subscript
)assignment
)expression_statement
)block
(except_clause
(identifier_KeyError) identifier_KeyError
(block
(raise_statement
(call
(identifier_KeyError) identifier_KeyError
(argument_list
(binary_operator
(string_'Unsupported busting method value: %s') string_'Unsupported busting method value: %s'
(identifier_method) identifier_method
)binary_operator
)argument_list
)call
)raise_statement
)block
)except_clause
)try_statement
(return_statement
(call
(identifier_fn) identifier_fn
(argument_list
(identifier_src_path) identifier_src_path
)argument_list
)call
)return_statement
)block
)function_definition
)module | Return a string that can be used as a parameter for cache-busting URLs
for this asset.
:param src_path:
Filesystem path to the file we're generating a cache-busting value for.
:param method:
Method for cache-busting. Supported values: importtime, mtime, md5
The default is 'importtime', because it requires the least processing.
Note that the mtime and md5 cache busting methods' results are cached on
the src_path.
Example::
>>> SRC_PATH = os.path.join(os.path.dirname(__file__), 'html.py')
>>> get_cache_buster(SRC_PATH) is _IMPORT_TIME
True
>>> get_cache_buster(SRC_PATH, method='mtime') == _cache_key_by_mtime(SRC_PATH)
True
>>> get_cache_buster(SRC_PATH, method='md5') == _cache_key_by_md5(SRC_PATH)
True |
(module
(function_definition
(function_name_validate) function_name_validate
(parameters
(identifier_self) identifier_self
(identifier_value) identifier_value
)parameters
(block
(if_statement
(comparison_operator
(attribute
(identifier_self) identifier_self
(identifier_validator) identifier_validator
)attribute
(None) None
)comparison_operator
(block
(try_statement
(block
(expression_statement
(assignment
(identifier_valid) identifier_valid
(call
(attribute
(identifier_self) identifier_self
(identifier_validator) identifier_validator
)attribute
(argument_list
(identifier_value) identifier_value
)argument_list
)call
)assignment
)expression_statement
)block
(except_clause
(as_pattern
(identifier_Exception) identifier_Exception
(as_pattern_target
(identifier_e) identifier_e
)as_pattern_target
)as_pattern
(block
(import_statement
(dotted_name
(identifier_pdb) identifier_pdb
)dotted_name
)import_statement
(expression_statement
(call
(attribute
(identifier_pdb) identifier_pdb
(identifier_set_trace) identifier_set_trace
)attribute
(argument_list
)argument_list
)call
)expression_statement
)block
)except_clause
)try_statement
(if_statement
(boolean_operator
(call
(identifier_isinstance) identifier_isinstance
(argument_list
(identifier_valid) identifier_valid
(identifier_tuple) identifier_tuple
)argument_list
)call
(comparison_operator
(call
(identifier_len) identifier_len
(argument_list
(identifier_valid) identifier_valid
)argument_list
)call
(integer_2) integer_2
)comparison_operator
)boolean_operator
(block
(expression_statement
(assignment
(pattern_list
(identifier_valid) identifier_valid
(identifier_errormsg) identifier_errormsg
)pattern_list
(identifier_valid) identifier_valid
)assignment
)expression_statement
)block
(elif_clause
(call
(identifier_isinstance) identifier_isinstance
(argument_list
(identifier_valid) identifier_valid
(identifier_bool) identifier_bool
)argument_list
)call
(block
(expression_statement
(assignment
(identifier_errormsg) identifier_errormsg
(string_"Invalid value") string_"Invalid value"
)assignment
)expression_statement
)block
)elif_clause
(else_clause
(block
(raise_statement
(call
(identifier_TypeError) identifier_TypeError
(argument_list
(string_"Custom validator must return a boolean or a (bool, errormsg) tuple.") string_"Custom validator must return a boolean or a (bool, errormsg) tuple."
)argument_list
)call
)raise_statement
)block
)else_clause
)if_statement
(if_statement
(identifier_valid) identifier_valid
(block
(expression_statement
(assignment
(attribute
(identifier_self) identifier_self
(identifier_error) identifier_error
)attribute
(None) None
)assignment
)expression_statement
)block
(else_clause
(block
(expression_statement
(assignment
(attribute
(identifier_self) identifier_self
(identifier_error) identifier_error
)attribute
(identifier_errormsg) identifier_errormsg
)assignment
)expression_statement
)block
)else_clause
)if_statement
(return_statement
(identifier_valid) identifier_valid
)return_statement
)block
(else_clause
(block
(expression_statement
(assignment
(attribute
(identifier_self) identifier_self
(identifier_error) identifier_error
)attribute
(None) None
)assignment
)expression_statement
(return_statement
(True) True
)return_statement
)block
)else_clause
)if_statement
)block
)function_definition
)module | Validate the parameter |
(module
(function_definition
(function_name_event_exists) function_name_event_exists
(parameters
(identifier_self) identifier_self
(identifier_client) identifier_client
(identifier_check) identifier_check
)parameters
(block
(return_statement
(comparison_operator
(attribute
(call
(attribute
(identifier_self) identifier_self
(identifier_api_request) identifier_api_request
)attribute
(argument_list
(string_'get') string_'get'
(call
(attribute
(string_'events/{}/{}') string_'events/{}/{}'
(identifier_format) identifier_format
)attribute
(argument_list
(identifier_client) identifier_client
(identifier_check) identifier_check
)argument_list
)call
)argument_list
)call
(identifier_status_code) identifier_status_code
)attribute
(integer_200) integer_200
)comparison_operator
)return_statement
)block
)function_definition
)module | Query Sensu API for event. |
(module
(function_definition
(function_name_bwrite) function_name_bwrite
(parameters
(identifier_stream) identifier_stream
(identifier_obj) identifier_obj
)parameters
(block
(expression_statement
(assignment
(identifier_handle) identifier_handle
(None) None
)assignment
)expression_statement
(if_statement
(not_operator
(call
(identifier_hasattr) identifier_hasattr
(argument_list
(identifier_stream) identifier_stream
(string_"write") string_"write"
)argument_list
)call
)not_operator
(block
(expression_statement
(assignment
(identifier_stream) identifier_stream
(assignment
(identifier_handle) identifier_handle
(call
(identifier_open) identifier_open
(argument_list
(identifier_stream) identifier_stream
(string_"wb") string_"wb"
)argument_list
)call
)assignment
)assignment
)expression_statement
)block
)if_statement
(try_statement
(block
(expression_statement
(call
(attribute
(identifier_stream) identifier_stream
(identifier_write) identifier_write
)attribute
(argument_list
(call
(identifier_bencode) identifier_bencode
(argument_list
(identifier_obj) identifier_obj
)argument_list
)call
)argument_list
)call
)expression_statement
)block
(finally_clause
(block
(if_statement
(identifier_handle) identifier_handle
(block
(expression_statement
(call
(attribute
(identifier_handle) identifier_handle
(identifier_close) identifier_close
)attribute
(argument_list
)argument_list
)call
)expression_statement
)block
)if_statement
)block
)finally_clause
)try_statement
)block
)function_definition
)module | Encode a given object to a file or stream. |
(module
(function_definition
(function_name_create) function_name_create
(parameters
(identifier_self) identifier_self
(identifier_to) identifier_to
(identifier_from_) identifier_from_
(default_parameter
(identifier_parameters) identifier_parameters
(attribute
(identifier_values) identifier_values
(identifier_unset) identifier_unset
)attribute
)default_parameter
)parameters
(block
(expression_statement
(assignment
(identifier_data) identifier_data
(call
(attribute
(identifier_values) identifier_values
(identifier_of) identifier_of
)attribute
(argument_list
(dictionary
(pair
(string_'To') string_'To'
(identifier_to) identifier_to
)pair
(pair
(string_'From') string_'From'
(identifier_from_) identifier_from_
)pair
(pair
(string_'Parameters') string_'Parameters'
(call
(attribute
(identifier_serialize) identifier_serialize
(identifier_object) identifier_object
)attribute
(argument_list
(identifier_parameters) identifier_parameters
)argument_list
)call
)pair
)dictionary
)argument_list
)call
)assignment
)expression_statement
(expression_statement
(assignment
(identifier_payload) identifier_payload
(call
(attribute
(attribute
(identifier_self) identifier_self
(identifier__version) identifier__version
)attribute
(identifier_create) identifier_create
)attribute
(argument_list
(string_'POST') string_'POST'
(attribute
(identifier_self) identifier_self
(identifier__uri) identifier__uri
)attribute
(keyword_argument
(identifier_data) identifier_data
(identifier_data) identifier_data
)keyword_argument
)argument_list
)call
)assignment
)expression_statement
(return_statement
(call
(identifier_ExecutionInstance) identifier_ExecutionInstance
(argument_list
(attribute
(identifier_self) identifier_self
(identifier__version) identifier__version
)attribute
(identifier_payload) identifier_payload
(keyword_argument
(identifier_flow_sid) identifier_flow_sid
(subscript
(attribute
(identifier_self) identifier_self
(identifier__solution) identifier__solution
)attribute
(string_'flow_sid') string_'flow_sid'
)subscript
)keyword_argument
)argument_list
)call
)return_statement
)block
)function_definition
)module | Create a new ExecutionInstance
:param unicode to: The Contact phone number to start a Studio Flow Execution.
:param unicode from_: The Twilio phone number to send messages or initiate calls from during the Flow Execution.
:param dict parameters: JSON data that will be added to your flow's context and can accessed as variables inside your flow.
:returns: Newly created ExecutionInstance
:rtype: twilio.rest.studio.v1.flow.execution.ExecutionInstance |
(module
(function_definition
(function_name_predictions_iter) function_name_predictions_iter
(parameters
(identifier_self) identifier_self
)parameters
(block
(for_statement
(identifier_fname) identifier_fname
(attribute
(identifier_self) identifier_self
(identifier_forecast_names) identifier_forecast_names
)attribute
(block
(expression_statement
(yield
(call
(attribute
(attribute
(identifier_self) identifier_self
(identifier_predictions) identifier_predictions
)attribute
(identifier_get) identifier_get
)attribute
(argument_list
(keyword_argument
(identifier_col_names) identifier_col_names
(identifier_fname) identifier_fname
)keyword_argument
)argument_list
)call
)yield
)expression_statement
)block
)for_statement
)block
)function_definition
)module | property decorated prediction iterator
Returns
-------
iterator : iterator
iterator on prediction sensitivity vectors (matrix) |
(module
(function_definition
(function_name_determine_version) function_name_determine_version
(parameters
(identifier_self) identifier_self
(identifier_request) identifier_request
(default_parameter
(identifier_api_version) identifier_api_version
(None) None
)default_parameter
)parameters
(block
(if_statement
(comparison_operator
(identifier_api_version) identifier_api_version
(False) False
)comparison_operator
(block
(expression_statement
(assignment
(identifier_api_version) identifier_api_version
(None) None
)assignment
)expression_statement
(for_statement
(identifier_version) identifier_version
(attribute
(identifier_self) identifier_self
(identifier_versions) identifier_versions
)attribute
(block
(if_statement
(boolean_operator
(identifier_version) identifier_version
(comparison_operator
(call
(attribute
(string_"v{0}") string_"v{0}"
(identifier_format) identifier_format
)attribute
(argument_list
(identifier_version) identifier_version
)argument_list
)call
(attribute
(identifier_request) identifier_request
(identifier_path) identifier_path
)attribute
)comparison_operator
)boolean_operator
(block
(expression_statement
(assignment
(identifier_api_version) identifier_api_version
(identifier_version) identifier_version
)assignment
)expression_statement
(break_statement
)break_statement
)block
)if_statement
)block
)for_statement
)block
)if_statement
(expression_statement
(assignment
(identifier_request_version) identifier_request_version
(call
(identifier_set) identifier_set
(argument_list
)argument_list
)call
)assignment
)expression_statement
(if_statement
(comparison_operator
(identifier_api_version) identifier_api_version
(None) None
)comparison_operator
(block
(expression_statement
(call
(attribute
(identifier_request_version) identifier_request_version
(identifier_add) identifier_add
)attribute
(argument_list
(identifier_api_version) identifier_api_version
)argument_list
)call
)expression_statement
)block
)if_statement
(expression_statement
(assignment
(identifier_version_header) identifier_version_header
(call
(attribute
(identifier_request) identifier_request
(identifier_get_header) identifier_get_header
)attribute
(argument_list
(string_"X-API-VERSION") string_"X-API-VERSION"
)argument_list
)call
)assignment
)expression_statement
(if_statement
(identifier_version_header) identifier_version_header
(block
(expression_statement
(call
(attribute
(identifier_request_version) identifier_request_version
(identifier_add) identifier_add
)attribute
(argument_list
(identifier_version_header) identifier_version_header
)argument_list
)call
)expression_statement
)block
)if_statement
(expression_statement
(assignment
(identifier_version_param) identifier_version_param
(call
(attribute
(identifier_request) identifier_request
(identifier_get_param) identifier_get_param
)attribute
(argument_list
(string_'api_version') string_'api_version'
)argument_list
)call
)assignment
)expression_statement
(if_statement
(comparison_operator
(identifier_version_param) identifier_version_param
(None) None
)comparison_operator
(block
(expression_statement
(call
(attribute
(identifier_request_version) identifier_request_version
(identifier_add) identifier_add
)attribute
(argument_list
(identifier_version_param) identifier_version_param
)argument_list
)call
)expression_statement
)block
)if_statement
(if_statement
(comparison_operator
(call
(identifier_len) identifier_len
(argument_list
(identifier_request_version) identifier_request_version
)argument_list
)call
(integer_1) integer_1
)comparison_operator
(block
(raise_statement
(call
(identifier_ValueError) identifier_ValueError
(argument_list
(string_'You are requesting conflicting versions') string_'You are requesting conflicting versions'
)argument_list
)call
)raise_statement
)block
)if_statement
(return_statement
(call
(identifier_next) identifier_next
(argument_list
(call
(identifier_iter) identifier_iter
(argument_list
(boolean_operator
(identifier_request_version) identifier_request_version
(tuple
(None) None
)tuple
)boolean_operator
)argument_list
)call
)argument_list
)call
)return_statement
)block
)function_definition
)module | Determines the appropriate version given the set api_version, the request header, and URL query params |
(module
(function_definition
(function_name_enable) function_name_enable
(parameters
(identifier_self) identifier_self
(default_parameter
(identifier_trigger_ids) identifier_trigger_ids
(list
)list
)default_parameter
)parameters
(block
(expression_statement
(assignment
(identifier_trigger_ids) identifier_trigger_ids
(call
(attribute
(string_',') string_','
(identifier_join) identifier_join
)attribute
(argument_list
(identifier_trigger_ids) identifier_trigger_ids
)argument_list
)call
)assignment
)expression_statement
(expression_statement
(assignment
(identifier_url) identifier_url
(call
(attribute
(identifier_self) identifier_self
(identifier__service_url) identifier__service_url
)attribute
(argument_list
(list
(string_'triggers') string_'triggers'
(string_'enabled') string_'enabled'
)list
(keyword_argument
(identifier_params) identifier_params
(dictionary
(pair
(string_'triggerIds') string_'triggerIds'
(identifier_trigger_ids) identifier_trigger_ids
)pair
(pair
(string_'enabled') string_'enabled'
(string_'true') string_'true'
)pair
)dictionary
)keyword_argument
)argument_list
)call
)assignment
)expression_statement
(expression_statement
(call
(attribute
(identifier_self) identifier_self
(identifier__put) identifier__put
)attribute
(argument_list
(identifier_url) identifier_url
(keyword_argument
(identifier_data) identifier_data
(None) None
)keyword_argument
(keyword_argument
(identifier_parse_json) identifier_parse_json
(False) False
)keyword_argument
)argument_list
)call
)expression_statement
)block
)function_definition
)module | Enable triggers.
:param trigger_ids: List of trigger definition ids to enable |
(module
(function_definition
(function_name_register_vcs_handler) function_name_register_vcs_handler
(parameters
(identifier_vcs) identifier_vcs
(identifier_method) identifier_method
)parameters
(block
(function_definition
(function_name_decorate) function_name_decorate
(parameters
(identifier_f) identifier_f
)parameters
(block
(if_statement
(comparison_operator
(identifier_vcs) identifier_vcs
(identifier_HANDLERS) identifier_HANDLERS
)comparison_operator
(block
(expression_statement
(assignment
(subscript
(identifier_HANDLERS) identifier_HANDLERS
(identifier_vcs) identifier_vcs
)subscript
(dictionary
)dictionary
)assignment
)expression_statement
)block
)if_statement
(expression_statement
(assignment
(subscript
(subscript
(identifier_HANDLERS) identifier_HANDLERS
(identifier_vcs) identifier_vcs
)subscript
(identifier_method) identifier_method
)subscript
(identifier_f) identifier_f
)assignment
)expression_statement
(return_statement
(identifier_f) identifier_f
)return_statement
)block
)function_definition
(return_statement
(identifier_decorate) identifier_decorate
)return_statement
)block
)function_definition
)module | Decorator to mark a method as the handler for a particular VCS. |
(module
(function_definition
(function_name_calc_checksum) function_name_calc_checksum
(parameters
(identifier_sentence) identifier_sentence
)parameters
(block
(if_statement
(call
(attribute
(identifier_sentence) identifier_sentence
(identifier_startswith) identifier_startswith
)attribute
(argument_list
(string_'$') string_'$'
)argument_list
)call
(block
(expression_statement
(assignment
(identifier_sentence) identifier_sentence
(subscript
(identifier_sentence) identifier_sentence
(slice
(integer_1) integer_1
(colon) colon
)slice
)subscript
)assignment
)expression_statement
)block
)if_statement
(expression_statement
(assignment
(identifier_sentence) identifier_sentence
(subscript
(call
(attribute
(identifier_sentence) identifier_sentence
(identifier_split) identifier_split
)attribute
(argument_list
(string_'*') string_'*'
)argument_list
)call
(integer_0) integer_0
)subscript
)assignment
)expression_statement
(return_statement
(call
(identifier_reduce) identifier_reduce
(argument_list
(identifier_xor) identifier_xor
(call
(identifier_map) identifier_map
(argument_list
(identifier_ord) identifier_ord
(identifier_sentence) identifier_sentence
)argument_list
)call
)argument_list
)call
)return_statement
)block
)function_definition
)module | Calculate a NMEA 0183 checksum for the given sentence.
NMEA checksums are a simple XOR of all the characters in the sentence
between the leading "$" symbol, and the "*" checksum separator.
Args:
sentence (str): NMEA 0183 formatted sentence |
(module
(function_definition
(function_name_convert) function_name_convert
(parameters
(identifier_source) identifier_source
(default_parameter
(identifier_ext) identifier_ext
(identifier_COMPLETE) identifier_COMPLETE
)default_parameter
(default_parameter
(identifier_fmt) identifier_fmt
(identifier_HTML) identifier_HTML
)default_parameter
(default_parameter
(identifier_dname) identifier_dname
(None) None
)default_parameter
)parameters
(block
(if_statement
(boolean_operator
(identifier_dname) identifier_dname
(not_operator
(binary_operator
(identifier_ext) identifier_ext
(identifier_COMPATIBILITY) identifier_COMPATIBILITY
)binary_operator
)not_operator
)boolean_operator
(block
(if_statement
(call
(attribute
(attribute
(identifier_os) identifier_os
(identifier_path) identifier_path
)attribute
(identifier_isfile) identifier_isfile
)attribute
(argument_list
(identifier_dname) identifier_dname
)argument_list
)call
(block
(expression_statement
(assignment
(identifier_dname) identifier_dname
(call
(attribute
(attribute
(identifier_os) identifier_os
(identifier_path) identifier_path
)attribute
(identifier_abspath) identifier_abspath
)attribute
(argument_list
(call
(attribute
(attribute
(identifier_os) identifier_os
(identifier_path) identifier_path
)attribute
(identifier_dirname) identifier_dirname
)attribute
(argument_list
(identifier_dname) identifier_dname
)argument_list
)call
)argument_list
)call
)assignment
)expression_statement
)block
)if_statement
(expression_statement
(assignment
(pattern_list
(identifier_source) identifier_source
(identifier__) identifier__
)pattern_list
(call
(identifier__expand_source) identifier__expand_source
(argument_list
(identifier_source) identifier_source
(identifier_dname) identifier_dname
(identifier_fmt) identifier_fmt
)argument_list
)call
)assignment
)expression_statement
)block
)if_statement
(expression_statement
(assignment
(attribute
(attribute
(identifier__MMD_LIB) identifier__MMD_LIB
(identifier_markdown_to_string) identifier_markdown_to_string
)attribute
(identifier_argtypes) identifier_argtypes
)attribute
(list
(attribute
(identifier_ctypes) identifier_ctypes
(identifier_c_char_p) identifier_c_char_p
)attribute
(attribute
(identifier_ctypes) identifier_ctypes
(identifier_c_ulong) identifier_c_ulong
)attribute
(attribute
(identifier_ctypes) identifier_ctypes
(identifier_c_int) identifier_c_int
)attribute
)list
)assignment
)expression_statement
(expression_statement
(assignment
(attribute
(attribute
(identifier__MMD_LIB) identifier__MMD_LIB
(identifier_markdown_to_string) identifier_markdown_to_string
)attribute
(identifier_restype) identifier_restype
)attribute
(attribute
(identifier_ctypes) identifier_ctypes
(identifier_c_char_p) identifier_c_char_p
)attribute
)assignment
)expression_statement
(expression_statement
(assignment
(identifier_src) identifier_src
(call
(attribute
(identifier_source) identifier_source
(identifier_encode) identifier_encode
)attribute
(argument_list
(string_'utf-8') string_'utf-8'
)argument_list
)call
)assignment
)expression_statement
(return_statement
(call
(attribute
(call
(attribute
(identifier__MMD_LIB) identifier__MMD_LIB
(identifier_markdown_to_string) identifier_markdown_to_string
)attribute
(argument_list
(identifier_src) identifier_src
(identifier_ext) identifier_ext
(identifier_fmt) identifier_fmt
)argument_list
)call
(identifier_decode) identifier_decode
)attribute
(argument_list
(string_'utf-8') string_'utf-8'
)argument_list
)call
)return_statement
)block
)function_definition
)module | Converts a string of MultiMarkdown text to the requested format.
Transclusion is performed if the COMPATIBILITY extension is not set, and dname is set to a
valid directory
Keyword arguments:
source -- string containing MultiMarkdown text
ext -- extension bitfield to pass to conversion process
fmt -- flag indicating output format to use
dname -- Path to use for transclusion - if None, transclusion functionality is bypassed |
(module
(function_definition
(function_name_load) function_name_load
(parameters
(identifier_self) identifier_self
(identifier_name) identifier_name
)parameters
(block
(expression_statement
(assignment
(identifier_name) identifier_name
(call
(attribute
(attribute
(identifier_ctypes) identifier_ctypes
(identifier_util) identifier_util
)attribute
(identifier_find_library) identifier_find_library
)attribute
(argument_list
(identifier_name) identifier_name
)argument_list
)call
)assignment
)expression_statement
(return_statement
(call
(attribute
(attribute
(identifier_ctypes) identifier_ctypes
(identifier_cdll) identifier_cdll
)attribute
(identifier_LoadLibrary) identifier_LoadLibrary
)attribute
(argument_list
(identifier_name) identifier_name
)argument_list
)call
)return_statement
)block
)function_definition
)module | Loads and returns foreign library. |
(module
(function_definition
(function_name__check_load_parameters) function_name__check_load_parameters
(parameters
(identifier_self) identifier_self
(dictionary_splat_pattern
(identifier_kwargs) identifier_kwargs
)dictionary_splat_pattern
)parameters
(block
(expression_statement
(assignment
(identifier_rset) identifier_rset
(subscript
(attribute
(identifier_self) identifier_self
(identifier__meta_data) identifier__meta_data
)attribute
(string_'required_load_parameters') string_'required_load_parameters'
)subscript
)assignment
)expression_statement
(expression_statement
(assignment
(identifier_check) identifier_check
(call
(identifier__missing_required_parameters) identifier__missing_required_parameters
(argument_list
(identifier_rset) identifier_rset
(dictionary_splat
(identifier_kwargs) identifier_kwargs
)dictionary_splat
)argument_list
)call
)assignment
)expression_statement
(if_statement
(identifier_check) identifier_check
(block
(expression_statement
(call
(attribute
(identifier_check) identifier_check
(identifier_sort) identifier_sort
)attribute
(argument_list
)argument_list
)call
)expression_statement
(expression_statement
(assignment
(identifier_error_message) identifier_error_message
(binary_operator
(string_'Missing required params: %s') string_'Missing required params: %s'
(identifier_check) identifier_check
)binary_operator
)assignment
)expression_statement
(raise_statement
(call
(identifier_MissingRequiredReadParameter) identifier_MissingRequiredReadParameter
(argument_list
(identifier_error_message) identifier_error_message
)argument_list
)call
)raise_statement
)block
)if_statement
)block
)function_definition
)module | Params given to load should at least satisfy required params.
:params: kwargs
:raises: MissingRequiredReadParameter |
(module
(function_definition
(function_name_region_by_identifier) function_name_region_by_identifier
(parameters
(identifier_self) identifier_self
(identifier_identifier) identifier_identifier
)parameters
(block
(if_statement
(comparison_operator
(identifier_identifier) identifier_identifier
(integer_0) integer_0
)comparison_operator
(block
(raise_statement
(parenthesized_expression
(call
(identifier_ValueError) identifier_ValueError
(argument_list
(string_"Identifier must be a positive integer.") string_"Identifier must be a positive integer."
)argument_list
)call
)parenthesized_expression
)raise_statement
)block
)if_statement
(if_statement
(not_operator
(call
(attribute
(identifier_np) identifier_np
(identifier_equal) identifier_equal
)attribute
(argument_list
(call
(attribute
(identifier_np) identifier_np
(identifier_mod) identifier_mod
)attribute
(argument_list
(identifier_identifier) identifier_identifier
(integer_1) integer_1
)argument_list
)call
(integer_0) integer_0
)argument_list
)call
)not_operator
(block
(raise_statement
(parenthesized_expression
(call
(identifier_ValueError) identifier_ValueError
(argument_list
(string_"Identifier must be a positive integer.") string_"Identifier must be a positive integer."
)argument_list
)call
)parenthesized_expression
)raise_statement
)block
)if_statement
(if_statement
(comparison_operator
(identifier_identifier) identifier_identifier
(integer_0) integer_0
)comparison_operator
(block
(raise_statement
(parenthesized_expression
(call
(identifier_ValueError) identifier_ValueError
(argument_list
(string_"0 represents the background.") string_"0 represents the background."
)argument_list
)call
)parenthesized_expression
)raise_statement
)block
)if_statement
(return_statement
(call
(attribute
(identifier_Region) identifier_Region
(identifier_select_from_array) identifier_select_from_array
)attribute
(argument_list
(identifier_self) identifier_self
(identifier_identifier) identifier_identifier
)argument_list
)call
)return_statement
)block
)function_definition
)module | Return region of interest corresponding to the supplied identifier.
:param identifier: integer corresponding to the segment of interest
:returns: `jicbioimage.core.region.Region` |
(module
(function_definition
(function_name_open) function_name_open
(parameters
(identifier_self) identifier_self
)parameters
(block
(if_statement
(not_operator
(attribute
(identifier_self) identifier_self
(identifier_handle) identifier_handle
)attribute
)not_operator
(block
(try_statement
(block
(expression_statement
(assignment
(identifier_path) identifier_path
(attribute
(identifier_self) identifier_self
(identifier_system_dir) identifier_system_dir
)attribute
)assignment
)expression_statement
)block
(except_clause
(identifier_AttributeError) identifier_AttributeError
(block
(expression_statement
(assignment
(identifier_path) identifier_path
(string_'') string_''
)assignment
)expression_statement
)block
)except_clause
)try_statement
(expression_statement
(assignment
(attribute
(identifier_self) identifier_self
(identifier___handle) identifier___handle
)attribute
(call
(identifier_lvm_init) identifier_lvm_init
(argument_list
(identifier_path) identifier_path
)argument_list
)call
)assignment
)expression_statement
(if_statement
(not_operator
(call
(identifier_bool) identifier_bool
(argument_list
(attribute
(identifier_self) identifier_self
(identifier___handle) identifier___handle
)attribute
)argument_list
)call
)not_operator
(block
(raise_statement
(call
(identifier_HandleError) identifier_HandleError
(argument_list
(string_"Failed to initialize LVM handle.") string_"Failed to initialize LVM handle."
)argument_list
)call
)raise_statement
)block
)if_statement
)block
)if_statement
)block
)function_definition
)module | Obtains the lvm handle. Usually you would never need to use this method unless
you are trying to do operations using the ctypes function wrappers in conversion.py
*Raises:*
* HandleError |
(module
(function_definition
(function_name_filter_by_analysis_period) function_name_filter_by_analysis_period
(parameters
(identifier_self) identifier_self
(identifier_analysis_period) identifier_analysis_period
)parameters
(block
(expression_statement
(call
(attribute
(identifier_self) identifier_self
(identifier__check_analysis_period) identifier__check_analysis_period
)attribute
(argument_list
(identifier_analysis_period) identifier_analysis_period
)argument_list
)call
)expression_statement
(expression_statement
(assignment
(identifier__filtered_data) identifier__filtered_data
(call
(attribute
(identifier_self) identifier_self
(identifier_filter_by_moys) identifier_filter_by_moys
)attribute
(argument_list
(attribute
(identifier_analysis_period) identifier_analysis_period
(identifier_moys) identifier_moys
)attribute
)argument_list
)call
)assignment
)expression_statement
(expression_statement
(assignment
(attribute
(attribute
(identifier__filtered_data) identifier__filtered_data
(identifier_header) identifier_header
)attribute
(identifier__analysis_period) identifier__analysis_period
)attribute
(identifier_analysis_period) identifier_analysis_period
)assignment
)expression_statement
(return_statement
(identifier__filtered_data) identifier__filtered_data
)return_statement
)block
)function_definition
)module | Filter a Data Collection based on an analysis period.
Args:
analysis period: A Ladybug analysis period
Return:
A new Data Collection with filtered data |
(module
(function_definition
(function_name_page_should_not_contain_text) function_name_page_should_not_contain_text
(parameters
(identifier_self) identifier_self
(identifier_text) identifier_text
(default_parameter
(identifier_loglevel) identifier_loglevel
(string_'INFO') string_'INFO'
)default_parameter
)parameters
(block
(if_statement
(call
(attribute
(identifier_self) identifier_self
(identifier__is_text_present) identifier__is_text_present
)attribute
(argument_list
(identifier_text) identifier_text
)argument_list
)call
(block
(expression_statement
(call
(attribute
(identifier_self) identifier_self
(identifier_log_source) identifier_log_source
)attribute
(argument_list
(identifier_loglevel) identifier_loglevel
)argument_list
)call
)expression_statement
(raise_statement
(call
(identifier_AssertionError) identifier_AssertionError
(argument_list
(binary_operator
(string_"Page should not have contained text '%s'") string_"Page should not have contained text '%s'"
(identifier_text) identifier_text
)binary_operator
)argument_list
)call
)raise_statement
)block
)if_statement
(expression_statement
(call
(attribute
(identifier_self) identifier_self
(identifier__info) identifier__info
)attribute
(argument_list
(binary_operator
(string_"Current page does not contains text '%s'.") string_"Current page does not contains text '%s'."
(identifier_text) identifier_text
)binary_operator
)argument_list
)call
)expression_statement
)block
)function_definition
)module | Verifies that current page not contains `text`.
If this keyword fails, it automatically logs the page source
using the log level specified with the optional `loglevel` argument.
Giving `NONE` as level disables logging. |
(module
(function_definition
(function_name_upsample) function_name_upsample
(parameters
(identifier_self) identifier_self
(identifier_factor) identifier_factor
)parameters
(block
(expression_statement
(call
(attribute
(identifier_self) identifier_self
(identifier_checkforpilimage) identifier_checkforpilimage
)attribute
(argument_list
)argument_list
)call
)expression_statement
(if_statement
(comparison_operator
(call
(identifier_type) identifier_type
(argument_list
(identifier_factor) identifier_factor
)argument_list
)call
(call
(identifier_type) identifier_type
(argument_list
(integer_0) integer_0
)argument_list
)call
)comparison_operator
(block
(raise_statement
(expression_list
(identifier_RuntimeError) identifier_RuntimeError
(string_"Upsample factor must be an integer !") string_"Upsample factor must be an integer !"
)expression_list
)raise_statement
)block
)if_statement
(if_statement
(attribute
(identifier_self) identifier_self
(identifier_verbose) identifier_verbose
)attribute
(block
(print_statement
(binary_operator
(string_"Upsampling by a factor of %i") string_"Upsampling by a factor of %i"
(identifier_factor) identifier_factor
)binary_operator
)print_statement
)block
)if_statement
(expression_statement
(assignment
(attribute
(identifier_self) identifier_self
(identifier_pilimage) identifier_pilimage
)attribute
(call
(attribute
(attribute
(identifier_self) identifier_self
(identifier_pilimage) identifier_pilimage
)attribute
(identifier_resize) identifier_resize
)attribute
(argument_list
(tuple
(binary_operator
(subscript
(attribute
(attribute
(identifier_self) identifier_self
(identifier_pilimage) identifier_pilimage
)attribute
(identifier_size) identifier_size
)attribute
(integer_0) integer_0
)subscript
(identifier_factor) identifier_factor
)binary_operator
(binary_operator
(subscript
(attribute
(attribute
(identifier_self) identifier_self
(identifier_pilimage) identifier_pilimage
)attribute
(identifier_size) identifier_size
)attribute
(integer_1) integer_1
)subscript
(identifier_factor) identifier_factor
)binary_operator
)tuple
)argument_list
)call
)assignment
)expression_statement
(expression_statement
(assignment
(attribute
(identifier_self) identifier_self
(identifier_upsamplefactor) identifier_upsamplefactor
)attribute
(identifier_factor) identifier_factor
)assignment
)expression_statement
(expression_statement
(assignment
(attribute
(identifier_self) identifier_self
(identifier_draw) identifier_draw
)attribute
(None) None
)assignment
)expression_statement
)block
)function_definition
)module | The inverse operation of rebin, applied on the PIL image.
Do this before writing text or drawing on the image !
The coordinates will be automatically converted for you |
(module
(function_definition
(function_name_set_proto_message_event) function_name_set_proto_message_event
(parameters
(identifier_pb_message_event) identifier_pb_message_event
(identifier_span_data_message_event) identifier_span_data_message_event
)parameters
(block
(expression_statement
(assignment
(attribute
(identifier_pb_message_event) identifier_pb_message_event
(identifier_type) identifier_type
)attribute
(attribute
(identifier_span_data_message_event) identifier_span_data_message_event
(identifier_type) identifier_type
)attribute
)assignment
)expression_statement
(expression_statement
(assignment
(attribute
(identifier_pb_message_event) identifier_pb_message_event
(identifier_id) identifier_id
)attribute
(attribute
(identifier_span_data_message_event) identifier_span_data_message_event
(identifier_id) identifier_id
)attribute
)assignment
)expression_statement
(expression_statement
(assignment
(attribute
(identifier_pb_message_event) identifier_pb_message_event
(identifier_uncompressed_size) identifier_uncompressed_size
)attribute
(line_continuation_\) line_continuation_\
(attribute
(identifier_span_data_message_event) identifier_span_data_message_event
(identifier_uncompressed_size_bytes) identifier_uncompressed_size_bytes
)attribute
)assignment
)expression_statement
(expression_statement
(assignment
(attribute
(identifier_pb_message_event) identifier_pb_message_event
(identifier_compressed_size) identifier_compressed_size
)attribute
(line_continuation_\) line_continuation_\
(attribute
(identifier_span_data_message_event) identifier_span_data_message_event
(identifier_compressed_size_bytes) identifier_compressed_size_bytes
)attribute
)assignment
)expression_statement
)block
)function_definition
)module | Sets properties on the protobuf message event.
:type pb_message_event:
:class: `~opencensus.proto.trace.Span.TimeEvent.MessageEvent`
:param pb_message_event: protobuf message event
:type span_data_message_event:
:class: `~opencensus.trace.time_event.MessageEvent`
:param span_data_message_event: opencensus message event |
(module
(function_definition
(function_name_to_dqflags) function_name_to_dqflags
(parameters
(identifier_self) identifier_self
(default_parameter
(identifier_bits) identifier_bits
(None) None
)default_parameter
(default_parameter
(identifier_minlen) identifier_minlen
(integer_1) integer_1
)default_parameter
(default_parameter
(identifier_dtype) identifier_dtype
(identifier_float) identifier_float
)default_parameter
(default_parameter
(identifier_round) identifier_round
(False) False
)default_parameter
)parameters
(block
(import_from_statement
(relative_import
(import_prefix
)import_prefix
(dotted_name
(identifier_segments) identifier_segments
)dotted_name
)relative_import
(dotted_name
(identifier_DataQualityDict) identifier_DataQualityDict
)dotted_name
)import_from_statement
(expression_statement
(assignment
(identifier_out) identifier_out
(call
(identifier_DataQualityDict) identifier_DataQualityDict
(argument_list
)argument_list
)call
)assignment
)expression_statement
(expression_statement
(assignment
(identifier_bitseries) identifier_bitseries
(call
(attribute
(identifier_self) identifier_self
(identifier_get_bit_series) identifier_get_bit_series
)attribute
(argument_list
(keyword_argument
(identifier_bits) identifier_bits
(identifier_bits) identifier_bits
)keyword_argument
)argument_list
)call
)assignment
)expression_statement
(for_statement
(pattern_list
(identifier_bit) identifier_bit
(identifier_sts) identifier_sts
)pattern_list
(call
(attribute
(identifier_bitseries) identifier_bitseries
(identifier_items) identifier_items
)attribute
(argument_list
)argument_list
)call
(block
(expression_statement
(assignment
(subscript
(identifier_out) identifier_out
(identifier_bit) identifier_bit
)subscript
(call
(attribute
(identifier_sts) identifier_sts
(identifier_to_dqflag) identifier_to_dqflag
)attribute
(argument_list
(keyword_argument
(identifier_name) identifier_name
(identifier_bit) identifier_bit
)keyword_argument
(keyword_argument
(identifier_minlen) identifier_minlen
(identifier_minlen) identifier_minlen
)keyword_argument
(keyword_argument
(identifier_round) identifier_round
(identifier_round) identifier_round
)keyword_argument
(keyword_argument
(identifier_dtype) identifier_dtype
(identifier_dtype) identifier_dtype
)keyword_argument
(keyword_argument
(identifier_description) identifier_description
(subscript
(attribute
(attribute
(identifier_self) identifier_self
(identifier_bits) identifier_bits
)attribute
(identifier_description) identifier_description
)attribute
(identifier_bit) identifier_bit
)subscript
)keyword_argument
)argument_list
)call
)assignment
)expression_statement
)block
)for_statement
(return_statement
(identifier_out) identifier_out
)return_statement
)block
)function_definition
)module | Convert this `StateVector` into a `~gwpy.segments.DataQualityDict`
The `StateTimeSeries` for each bit is converted into a
`~gwpy.segments.DataQualityFlag` with the bits combined into a dict.
Parameters
----------
minlen : `int`, optional, default: 1
minimum number of consecutive `True` values to identify as a
`Segment`. This is useful to ignore single bit flips,
for example.
bits : `list`, optional
a list of bit indices or bit names to select, defaults to
`~StateVector.bits`
Returns
-------
DataQualityFlag list : `list`
a list of `~gwpy.segments.flag.DataQualityFlag`
reprensentations for each bit in this `StateVector`
See Also
--------
:meth:`StateTimeSeries.to_dqflag`
for details on the segment representation method for
`StateVector` bits |
(module
(function_definition
(function_name_get_categorical_feature_names) function_name_get_categorical_feature_names
(parameters
(identifier_example) identifier_example
)parameters
(block
(expression_statement
(assignment
(identifier_features) identifier_features
(call
(identifier_get_example_features) identifier_get_example_features
(argument_list
(identifier_example) identifier_example
)argument_list
)call
)assignment
)expression_statement
(return_statement
(call
(identifier_sorted) identifier_sorted
(argument_list
(list_comprehension
(identifier_feature_name) identifier_feature_name
(for_in_clause
(identifier_feature_name) identifier_feature_name
(identifier_features) identifier_features
)for_in_clause
(if_clause
(comparison_operator
(call
(attribute
(subscript
(identifier_features) identifier_features
(identifier_feature_name) identifier_feature_name
)subscript
(identifier_WhichOneof) identifier_WhichOneof
)attribute
(argument_list
(string_'kind') string_'kind'
)argument_list
)call
(string_'bytes_list') string_'bytes_list'
)comparison_operator
)if_clause
)list_comprehension
)argument_list
)call
)return_statement
)block
)function_definition
)module | Returns a list of feature names for byte type features.
Args:
example: An example.
Returns:
A list of categorical feature names (e.g. ['education', 'marital_status'] ) |
(module
(function_definition
(function_name__check_and_handle_includes) function_name__check_and_handle_includes
(parameters
(identifier_self) identifier_self
(identifier_from_file) identifier_from_file
)parameters
(block
(expression_statement
(call
(attribute
(identifier_logger) identifier_logger
(identifier_debug) identifier_debug
)attribute
(argument_list
(string_"Check/handle includes from %s") string_"Check/handle includes from %s"
(identifier_from_file) identifier_from_file
)argument_list
)call
)expression_statement
(try_statement
(block
(expression_statement
(assignment
(identifier_paths) identifier_paths
(call
(attribute
(attribute
(identifier_self) identifier_self
(identifier__parser) identifier__parser
)attribute
(identifier_get) identifier_get
)attribute
(argument_list
(string_"INCLUDE") string_"INCLUDE"
(string_"paths") string_"paths"
)argument_list
)call
)assignment
)expression_statement
)block
(except_clause
(as_pattern
(tuple
(attribute
(identifier_config_parser) identifier_config_parser
(identifier_NoSectionError) identifier_NoSectionError
)attribute
(attribute
(identifier_config_parser) identifier_config_parser
(identifier_NoOptionError) identifier_NoOptionError
)attribute
)tuple
(as_pattern_target
(identifier_exc) identifier_exc
)as_pattern_target
)as_pattern
(block
(expression_statement
(call
(attribute
(identifier_logger) identifier_logger
(identifier_debug) identifier_debug
)attribute
(argument_list
(string_"_check_and_handle_includes: EXCEPTION: %s") string_"_check_and_handle_includes: EXCEPTION: %s"
(identifier_exc) identifier_exc
)argument_list
)call
)expression_statement
(return_statement
)return_statement
)block
)except_clause
)try_statement
(expression_statement
(assignment
(identifier_paths_lines) identifier_paths_lines
(list_comprehension
(call
(attribute
(identifier_p) identifier_p
(identifier_strip) identifier_strip
)attribute
(argument_list
)argument_list
)call
(for_in_clause
(identifier_p) identifier_p
(call
(attribute
(identifier_paths) identifier_paths
(identifier_split) identifier_split
)attribute
(argument_list
(string_"\n") string_"\n"
)argument_list
)call
)for_in_clause
)list_comprehension
)assignment
)expression_statement
(expression_statement
(call
(attribute
(identifier_logger) identifier_logger
(identifier_debug) identifier_debug
)attribute
(argument_list
(string_"paths = %s (wanted just once; CLEARING)") string_"paths = %s (wanted just once; CLEARING)"
(identifier_paths_lines) identifier_paths_lines
)argument_list
)call
)expression_statement
(expression_statement
(call
(attribute
(attribute
(identifier_self) identifier_self
(identifier__parser) identifier__parser
)attribute
(identifier_remove_option) identifier_remove_option
)attribute
(argument_list
(string_"INCLUDE") string_"INCLUDE"
(string_"paths") string_"paths"
)argument_list
)call
)expression_statement
(for_statement
(identifier_f) identifier_f
(identifier_paths_lines) identifier_paths_lines
(block
(expression_statement
(assignment
(identifier_abspath) identifier_abspath
(parenthesized_expression
(conditional_expression
(identifier_f) identifier_f
(call
(attribute
(attribute
(identifier_os) identifier_os
(identifier_path) identifier_path
)attribute
(identifier_isabs) identifier_isabs
)attribute
(argument_list
(identifier_f) identifier_f
)argument_list
)call
(call
(attribute
(attribute
(identifier_os) identifier_os
(identifier_path) identifier_path
)attribute
(identifier_abspath) identifier_abspath
)attribute
(argument_list
(call
(attribute
(attribute
(identifier_os) identifier_os
(identifier_path) identifier_path
)attribute
(identifier_join) identifier_join
)attribute
(argument_list
(call
(attribute
(attribute
(identifier_os) identifier_os
(identifier_path) identifier_path
)attribute
(identifier_dirname) identifier_dirname
)attribute
(argument_list
(identifier_from_file) identifier_from_file
)argument_list
)call
(identifier_f) identifier_f
)argument_list
)call
)argument_list
)call
)conditional_expression
)parenthesized_expression
)assignment
)expression_statement
(expression_statement
(assignment
(identifier_use_path) identifier_use_path
(call
(attribute
(attribute
(identifier_os) identifier_os
(identifier_path) identifier_path
)attribute
(identifier_normpath) identifier_normpath
)attribute
(argument_list
(identifier_abspath) identifier_abspath
)argument_list
)call
)assignment
)expression_statement
(if_statement
(comparison_operator
(identifier_use_path) identifier_use_path
(attribute
(identifier_self) identifier_self
(identifier__parsed_files) identifier__parsed_files
)attribute
)comparison_operator
(block
(raise_statement
(call
(identifier_RecursionInConfigFile) identifier_RecursionInConfigFile
(argument_list
(string_"In %s: %s already read") string_"In %s: %s already read"
(identifier_from_file) identifier_from_file
(identifier_use_path) identifier_use_path
)argument_list
)call
)raise_statement
)block
)if_statement
(expression_statement
(call
(attribute
(attribute
(identifier_self) identifier_self
(identifier__parsed_files) identifier__parsed_files
)attribute
(identifier_append) identifier_append
)attribute
(argument_list
(identifier_use_path) identifier_use_path
)argument_list
)call
)expression_statement
(expression_statement
(call
(attribute
(identifier_self) identifier_self
(identifier__handle_rc_file) identifier__handle_rc_file
)attribute
(argument_list
(identifier_use_path) identifier_use_path
)argument_list
)call
)expression_statement
)block
)for_statement
)block
)function_definition
)module | Look for an optional INCLUDE section in the given file path. If
the parser set `paths`, it is cleared so that they do not keep
showing up when additional files are parsed. |
(module
(function_definition
(function_name__print_results) function_name__print_results
(parameters
(identifier_file) identifier_file
(identifier_status) identifier_status
)parameters
(block
(expression_statement
(assignment
(identifier_file_color) identifier_file_color
(attribute
(attribute
(identifier_c) identifier_c
(identifier_Fore) identifier_Fore
)attribute
(identifier_GREEN) identifier_GREEN
)attribute
)assignment
)expression_statement
(expression_statement
(assignment
(identifier_status_color) identifier_status_color
(attribute
(attribute
(identifier_c) identifier_c
(identifier_Fore) identifier_Fore
)attribute
(identifier_RED) identifier_RED
)attribute
)assignment
)expression_statement
(if_statement
(comparison_operator
(identifier_status) identifier_status
(string_'Success') string_'Success'
)comparison_operator
(block
(expression_statement
(assignment
(identifier_status_color) identifier_status_color
(attribute
(attribute
(identifier_c) identifier_c
(identifier_Fore) identifier_Fore
)attribute
(identifier_GREEN) identifier_GREEN
)attribute
)assignment
)expression_statement
)block
(elif_clause
(comparison_operator
(identifier_status) identifier_status
(string_'Skipped') string_'Skipped'
)comparison_operator
(block
(expression_statement
(assignment
(identifier_status_color) identifier_status_color
(attribute
(attribute
(identifier_c) identifier_c
(identifier_Fore) identifier_Fore
)attribute
(identifier_YELLOW) identifier_YELLOW
)attribute
)assignment
)expression_statement
)block
)elif_clause
)if_statement
(expression_statement
(call
(identifier_print) identifier_print
(argument_list
(call
(attribute
(string_'{}{!s:<13}{}{!s:<35}{}{!s:<8}{}{}') string_'{}{!s:<13}{}{!s:<35}{}{!s:<8}{}{}'
(identifier_format) identifier_format
)attribute
(argument_list
(attribute
(attribute
(identifier_c) identifier_c
(identifier_Fore) identifier_Fore
)attribute
(identifier_CYAN) identifier_CYAN
)attribute
(string_'Downloading:') string_'Downloading:'
(identifier_file_color) identifier_file_color
(identifier_file) identifier_file
(attribute
(attribute
(identifier_c) identifier_c
(identifier_Fore) identifier_Fore
)attribute
(identifier_CYAN) identifier_CYAN
)attribute
(string_'Status:') string_'Status:'
(identifier_status_color) identifier_status_color
(identifier_status) identifier_status
)argument_list
)call
)argument_list
)call
)expression_statement
)block
)function_definition
)module | Print the download results.
Args:
file (str): The filename.
status (str): The file download status. |
(module
(function_definition
(function_name_rebalance_replicas) function_name_rebalance_replicas
(parameters
(identifier_self) identifier_self
(default_parameter
(identifier_max_movement_count) identifier_max_movement_count
(None) None
)default_parameter
(default_parameter
(identifier_max_movement_size) identifier_max_movement_size
(None) None
)default_parameter
)parameters
(block
(expression_statement
(assignment
(identifier_movement_count) identifier_movement_count
(integer_0) integer_0
)assignment
)expression_statement
(expression_statement
(assignment
(identifier_movement_size) identifier_movement_size
(integer_0) integer_0
)assignment
)expression_statement
(for_statement
(identifier_partition) identifier_partition
(call
(attribute
(identifier_six) identifier_six
(identifier_itervalues) identifier_itervalues
)attribute
(argument_list
(attribute
(attribute
(identifier_self) identifier_self
(identifier_cluster_topology) identifier_cluster_topology
)attribute
(identifier_partitions) identifier_partitions
)attribute
)argument_list
)call
(block
(expression_statement
(assignment
(pattern_list
(identifier_count) identifier_count
(identifier_size) identifier_size
)pattern_list
(call
(attribute
(identifier_self) identifier_self
(identifier__rebalance_partition_replicas) identifier__rebalance_partition_replicas
)attribute
(argument_list
(identifier_partition) identifier_partition
(conditional_expression
(None) None
(not_operator
(identifier_max_movement_count) identifier_max_movement_count
)not_operator
(binary_operator
(identifier_max_movement_count) identifier_max_movement_count
(identifier_movement_count) identifier_movement_count
)binary_operator
)conditional_expression
(conditional_expression
(None) None
(not_operator
(identifier_max_movement_size) identifier_max_movement_size
)not_operator
(binary_operator
(identifier_max_movement_size) identifier_max_movement_size
(identifier_movement_size) identifier_movement_size
)binary_operator
)conditional_expression
)argument_list
)call
)assignment
)expression_statement
(expression_statement
(augmented_assignment
(identifier_movement_count) identifier_movement_count
(identifier_count) identifier_count
)augmented_assignment
)expression_statement
(expression_statement
(augmented_assignment
(identifier_movement_size) identifier_movement_size
(identifier_size) identifier_size
)augmented_assignment
)expression_statement
)block
)for_statement
(return_statement
(expression_list
(identifier_movement_count) identifier_movement_count
(identifier_movement_size) identifier_movement_size
)expression_list
)return_statement
)block
)function_definition
)module | Balance replicas across replication-groups.
:param max_movement_count: The maximum number of partitions to move.
:param max_movement_size: The maximum total size of the partitions to move.
:returns: A 2-tuple whose first element is the number of partitions moved
and whose second element is the total size of the partitions moved. |
(module
(function_definition
(function_name__send_script) function_name__send_script
(parameters
(identifier_self) identifier_self
(identifier_device_info) identifier_device_info
(identifier_control_info) identifier_control_info
(identifier_script) identifier_script
(identifier_progress_callback) identifier_progress_callback
)parameters
(block
(for_statement
(identifier_i) identifier_i
(call
(identifier_range) identifier_range
(argument_list
(integer_0) integer_0
(call
(identifier_len) identifier_len
(argument_list
(identifier_script) identifier_script
)argument_list
)call
(integer_20) integer_20
)argument_list
)call
(block
(expression_statement
(assignment
(identifier_chunk) identifier_chunk
(subscript
(identifier_script) identifier_script
(slice
(identifier_i) identifier_i
(colon) colon
(binary_operator
(identifier_i) identifier_i
(integer_20) integer_20
)binary_operator
)slice
)subscript
)assignment
)expression_statement
(expression_statement
(call
(attribute
(identifier_self) identifier_self
(identifier__send_rpc) identifier__send_rpc
)attribute
(argument_list
(identifier_device_info) identifier_device_info
(identifier_control_info) identifier_control_info
(integer_8) integer_8
(integer_0x2101) integer_0x2101
(identifier_chunk) identifier_chunk
(float_0.001) float_0.001
(float_1.0) float_1.0
)argument_list
)call
)expression_statement
(if_statement
(comparison_operator
(identifier_progress_callback) identifier_progress_callback
(None) None
)comparison_operator
(block
(expression_statement
(call
(identifier_progress_callback) identifier_progress_callback
(argument_list
(binary_operator
(identifier_i) identifier_i
(call
(identifier_len) identifier_len
(argument_list
(identifier_chunk) identifier_chunk
)argument_list
)call
)binary_operator
(call
(identifier_len) identifier_len
(argument_list
(identifier_script) identifier_script
)argument_list
)call
)argument_list
)call
)expression_statement
)block
)if_statement
)block
)for_statement
)block
)function_definition
)module | Send a script by repeatedly sending it as a bunch of RPCs.
This function doesn't do anything special, it just sends a bunch of RPCs
with each chunk of the script until it's finished. |
(module
(function_definition
(function_name_filter_dependencies) function_name_filter_dependencies
(parameters
(identifier_self) identifier_self
)parameters
(block
(expression_statement
(assignment
(identifier_dependencies) identifier_dependencies
(call
(attribute
(subscript
(attribute
(identifier_self) identifier_self
(identifier_event) identifier_event
)attribute
(string_'check') string_'check'
)subscript
(identifier_get) identifier_get
)attribute
(argument_list
(string_'dependencies') string_'dependencies'
(None) None
)argument_list
)call
)assignment
)expression_statement
(if_statement
(boolean_operator
(comparison_operator
(identifier_dependencies) identifier_dependencies
(None) None
)comparison_operator
(not_operator
(call
(identifier_isinstance) identifier_isinstance
(argument_list
(identifier_dependencies) identifier_dependencies
(identifier_list) identifier_list
)argument_list
)call
)not_operator
)boolean_operator
(block
(return_statement
)return_statement
)block
)if_statement
(for_statement
(identifier_dependency) identifier_dependency
(subscript
(subscript
(attribute
(identifier_self) identifier_self
(identifier_event) identifier_event
)attribute
(string_'check') string_'check'
)subscript
(string_'dependencies') string_'dependencies'
)subscript
(block
(if_statement
(not_operator
(call
(identifier_str) identifier_str
(argument_list
(identifier_dependency) identifier_dependency
)argument_list
)call
)not_operator
(block
(continue_statement
)continue_statement
)block
)if_statement
(expression_statement
(assignment
(identifier_dependency_split) identifier_dependency_split
(call
(identifier_tuple) identifier_tuple
(argument_list
(call
(attribute
(identifier_dependency) identifier_dependency
(identifier_split) identifier_split
)attribute
(argument_list
(string_'/') string_'/'
)argument_list
)call
)argument_list
)call
)assignment
)expression_statement
(if_statement
(comparison_operator
(call
(identifier_len) identifier_len
(argument_list
(identifier_dependency_split) identifier_dependency_split
)argument_list
)call
(integer_2) integer_2
)comparison_operator
(block
(expression_statement
(assignment
(pattern_list
(identifier_client) identifier_client
(identifier_check) identifier_check
)pattern_list
(identifier_dependency_split) identifier_dependency_split
)assignment
)expression_statement
)block
(else_clause
(block
(expression_statement
(assignment
(identifier_client) identifier_client
(subscript
(subscript
(attribute
(identifier_self) identifier_self
(identifier_event) identifier_event
)attribute
(string_'client') string_'client'
)subscript
(string_'name') string_'name'
)subscript
)assignment
)expression_statement
(expression_statement
(assignment
(identifier_check) identifier_check
(subscript
(identifier_dependency_split) identifier_dependency_split
(integer_0) integer_0
)subscript
)assignment
)expression_statement
)block
)else_clause
)if_statement
(if_statement
(call
(attribute
(identifier_self) identifier_self
(identifier_event_exists) identifier_event_exists
)attribute
(argument_list
(identifier_client) identifier_client
(identifier_check) identifier_check
)argument_list
)call
(block
(expression_statement
(call
(attribute
(identifier_self) identifier_self
(identifier_bail) identifier_bail
)attribute
(argument_list
(string_'check dependency event exists') string_'check dependency event exists'
)argument_list
)call
)expression_statement
)block
)if_statement
)block
)for_statement
)block
)function_definition
)module | Determine whether a check has dependencies. |
(module
(function_definition
(function_name_get_parameters) function_name_get_parameters
(parameters
(identifier_self) identifier_self
(identifier_params) identifier_params
(default_parameter
(identifier_graph) identifier_graph
(None) None
)default_parameter
)parameters
(block
(expression_statement
(assignment
(identifier_g) identifier_g
(conditional_expression
(identifier_graph) identifier_graph
(comparison_operator
(identifier_graph) identifier_graph
(None) None
)comparison_operator
(attribute
(identifier_self) identifier_self
(identifier_tf_graph) identifier_tf_graph
)attribute
)conditional_expression
)assignment
)expression_statement
(with_statement
(with_clause
(with_item
(call
(attribute
(identifier_g) identifier_g
(identifier_as_default) identifier_as_default
)attribute
(argument_list
)argument_list
)call
)with_item
)with_clause
(block
(with_statement
(with_clause
(with_item
(as_pattern
(call
(attribute
(identifier_tf) identifier_tf
(identifier_Session) identifier_Session
)attribute
(argument_list
)argument_list
)call
(as_pattern_target
(attribute
(identifier_self) identifier_self
(identifier_tf_session) identifier_tf_session
)attribute
)as_pattern_target
)as_pattern
)with_item
)with_clause
(block
(expression_statement
(call
(attribute
(attribute
(identifier_self) identifier_self
(identifier_tf_saver) identifier_tf_saver
)attribute
(identifier_restore) identifier_restore
)attribute
(argument_list
(attribute
(identifier_self) identifier_self
(identifier_tf_session) identifier_tf_session
)attribute
(attribute
(identifier_self) identifier_self
(identifier_model_path) identifier_model_path
)attribute
)argument_list
)call
)expression_statement
(expression_statement
(assignment
(identifier_out) identifier_out
(dictionary
)dictionary
)assignment
)expression_statement
(for_statement
(identifier_par) identifier_par
(identifier_params) identifier_params
(block
(if_statement
(comparison_operator
(call
(identifier_type) identifier_type
(argument_list
(subscript
(identifier_params) identifier_params
(identifier_par) identifier_par
)subscript
)argument_list
)call
(identifier_list) identifier_list
)comparison_operator
(block
(for_statement
(pattern_list
(identifier_i) identifier_i
(identifier_p) identifier_p
)pattern_list
(call
(identifier_enumerate) identifier_enumerate
(argument_list
(subscript
(identifier_params) identifier_params
(identifier_par) identifier_par
)subscript
)argument_list
)call
(block
(expression_statement
(assignment
(subscript
(identifier_out) identifier_out
(binary_operator
(binary_operator
(identifier_par) identifier_par
(string_'-') string_'-'
)binary_operator
(call
(identifier_str) identifier_str
(argument_list
(binary_operator
(identifier_i) identifier_i
(integer_1) integer_1
)binary_operator
)argument_list
)call
)binary_operator
)subscript
(call
(attribute
(identifier_p) identifier_p
(identifier_eval) identifier_eval
)attribute
(argument_list
)argument_list
)call
)assignment
)expression_statement
)block
)for_statement
)block
(else_clause
(block
(expression_statement
(assignment
(subscript
(identifier_out) identifier_out
(identifier_par) identifier_par
)subscript
(call
(attribute
(subscript
(identifier_params) identifier_params
(identifier_par) identifier_par
)subscript
(identifier_eval) identifier_eval
)attribute
(argument_list
)argument_list
)call
)assignment
)expression_statement
)block
)else_clause
)if_statement
)block
)for_statement
(return_statement
(identifier_out) identifier_out
)return_statement
)block
)with_statement
)block
)with_statement
)block
)function_definition
)module | Get the parameters of the model.
:param params: dictionary of keys (str names) and values (tensors).
:return: evaluated tensors in params |
(module
(function_definition
(function_name_txn_getAssociation) function_name_txn_getAssociation
(parameters
(identifier_self) identifier_self
(identifier_server_url) identifier_server_url
(default_parameter
(identifier_handle) identifier_handle
(None) None
)default_parameter
)parameters
(block
(if_statement
(comparison_operator
(identifier_handle) identifier_handle
(None) None
)comparison_operator
(block
(expression_statement
(call
(attribute
(identifier_self) identifier_self
(identifier_db_get_assoc) identifier_db_get_assoc
)attribute
(argument_list
(identifier_server_url) identifier_server_url
(identifier_handle) identifier_handle
)argument_list
)call
)expression_statement
)block
(else_clause
(block
(expression_statement
(call
(attribute
(identifier_self) identifier_self
(identifier_db_get_assocs) identifier_db_get_assocs
)attribute
(argument_list
(identifier_server_url) identifier_server_url
)argument_list
)call
)expression_statement
)block
)else_clause
)if_statement
(expression_statement
(assignment
(identifier_rows) identifier_rows
(call
(attribute
(attribute
(identifier_self) identifier_self
(identifier_cur) identifier_cur
)attribute
(identifier_fetchall) identifier_fetchall
)attribute
(argument_list
)argument_list
)call
)assignment
)expression_statement
(if_statement
(comparison_operator
(call
(identifier_len) identifier_len
(argument_list
(identifier_rows) identifier_rows
)argument_list
)call
(integer_0) integer_0
)comparison_operator
(block
(return_statement
(None) None
)return_statement
)block
(else_clause
(block
(expression_statement
(assignment
(identifier_associations) identifier_associations
(list
)list
)assignment
)expression_statement
(for_statement
(identifier_values) identifier_values
(identifier_rows) identifier_rows
(block
(expression_statement
(assignment
(identifier_values) identifier_values
(call
(identifier_list) identifier_list
(argument_list
(identifier_values) identifier_values
)argument_list
)call
)assignment
)expression_statement
(expression_statement
(assignment
(subscript
(identifier_values) identifier_values
(integer_1) integer_1
)subscript
(call
(attribute
(identifier_self) identifier_self
(identifier_blobDecode) identifier_blobDecode
)attribute
(argument_list
(subscript
(identifier_values) identifier_values
(integer_1) integer_1
)subscript
)argument_list
)call
)assignment
)expression_statement
(expression_statement
(assignment
(identifier_assoc) identifier_assoc
(call
(identifier_Association) identifier_Association
(argument_list
(list_splat
(identifier_values) identifier_values
)list_splat
)argument_list
)call
)assignment
)expression_statement
(if_statement
(comparison_operator
(attribute
(identifier_assoc) identifier_assoc
(identifier_expiresIn) identifier_expiresIn
)attribute
(integer_0) integer_0
)comparison_operator
(block
(expression_statement
(call
(attribute
(identifier_self) identifier_self
(identifier_txn_removeAssociation) identifier_txn_removeAssociation
)attribute
(argument_list
(identifier_server_url) identifier_server_url
(attribute
(identifier_assoc) identifier_assoc
(identifier_handle) identifier_handle
)attribute
)argument_list
)call
)expression_statement
)block
(else_clause
(block
(expression_statement
(call
(attribute
(identifier_associations) identifier_associations
(identifier_append) identifier_append
)attribute
(argument_list
(tuple
(attribute
(identifier_assoc) identifier_assoc
(identifier_issued) identifier_issued
)attribute
(identifier_assoc) identifier_assoc
)tuple
)argument_list
)call
)expression_statement
)block
)else_clause
)if_statement
)block
)for_statement
(if_statement
(identifier_associations) identifier_associations
(block
(expression_statement
(call
(attribute
(identifier_associations) identifier_associations
(identifier_sort) identifier_sort
)attribute
(argument_list
)argument_list
)call
)expression_statement
(return_statement
(subscript
(subscript
(identifier_associations) identifier_associations
(unary_operator
(integer_1) integer_1
)unary_operator
)subscript
(integer_1) integer_1
)subscript
)return_statement
)block
(else_clause
(block
(return_statement
(None) None
)return_statement
)block
)else_clause
)if_statement
)block
)else_clause
)if_statement
)block
)function_definition
)module | Get the most recent association that has been set for this
server URL and handle.
str -> NoneType or Association |
(module
(function_definition
(function_name_pysal_Moran) function_name_pysal_Moran
(parameters
(identifier_self) identifier_self
(dictionary_splat_pattern
(identifier_kwargs) identifier_kwargs
)dictionary_splat_pattern
)parameters
(block
(if_statement
(comparison_operator
(attribute
(identifier_self) identifier_self
(identifier_weights) identifier_weights
)attribute
(None) None
)comparison_operator
(block
(expression_statement
(call
(attribute
(identifier_self) identifier_self
(identifier_raster_weights) identifier_raster_weights
)attribute
(argument_list
(dictionary_splat
(identifier_kwargs) identifier_kwargs
)dictionary_splat
)argument_list
)call
)expression_statement
)block
)if_statement
(expression_statement
(assignment
(identifier_rasterf) identifier_rasterf
(call
(attribute
(attribute
(identifier_self) identifier_self
(identifier_raster) identifier_raster
)attribute
(identifier_flatten) identifier_flatten
)attribute
(argument_list
)argument_list
)call
)assignment
)expression_statement
(expression_statement
(assignment
(identifier_rasterf) identifier_rasterf
(subscript
(identifier_rasterf) identifier_rasterf
(comparison_operator
(attribute
(identifier_rasterf) identifier_rasterf
(identifier_mask) identifier_mask
)attribute
(False) False
)comparison_operator
)subscript
)assignment
)expression_statement
(expression_statement
(assignment
(attribute
(identifier_self) identifier_self
(identifier_Moran) identifier_Moran
)attribute
(call
(attribute
(identifier_pysal) identifier_pysal
(identifier_Moran) identifier_Moran
)attribute
(argument_list
(identifier_rasterf) identifier_rasterf
(attribute
(identifier_self) identifier_self
(identifier_weights) identifier_weights
)attribute
(dictionary_splat
(identifier_kwargs) identifier_kwargs
)dictionary_splat
)argument_list
)call
)assignment
)expression_statement
)block
)function_definition
)module | Compute Moran's I measure of global spatial autocorrelation for GeoRaster
Usage:
geo.pysal_Moran(permutations = 1000, rook=True)
arguments passed to raster_weights() and pysal.Moran
See help(gr.raster_weights), help(pysal.Moran) for options |
(module
(function_definition
(function_name__connect_sentinel) function_name__connect_sentinel
(parameters
(identifier_self) identifier_self
(identifier_address) identifier_address
(identifier_timeout) identifier_timeout
(identifier_pools) identifier_pools
)parameters
(block
(try_statement
(block
(with_statement
(with_clause
(with_item
(call
(identifier_async_timeout) identifier_async_timeout
(argument_list
(identifier_timeout) identifier_timeout
(keyword_argument
(identifier_loop) identifier_loop
(attribute
(identifier_self) identifier_self
(identifier__loop) identifier__loop
)attribute
)keyword_argument
)argument_list
)call
)with_item
)with_clause
(block
(expression_statement
(assignment
(identifier_pool) identifier_pool
(await
(call
(identifier_create_pool) identifier_create_pool
(argument_list
(identifier_address) identifier_address
(keyword_argument
(identifier_minsize) identifier_minsize
(integer_1) integer_1
)keyword_argument
(keyword_argument
(identifier_maxsize) identifier_maxsize
(integer_2) integer_2
)keyword_argument
(keyword_argument
(identifier_parser) identifier_parser
(attribute
(identifier_self) identifier_self
(identifier__parser_class) identifier__parser_class
)attribute
)keyword_argument
(keyword_argument
(identifier_loop) identifier_loop
(attribute
(identifier_self) identifier_self
(identifier__loop) identifier__loop
)attribute
)keyword_argument
)argument_list
)call
)await
)assignment
)expression_statement
)block
)with_statement
(expression_statement
(call
(attribute
(identifier_pools) identifier_pools
(identifier_append) identifier_append
)attribute
(argument_list
(identifier_pool) identifier_pool
)argument_list
)call
)expression_statement
(return_statement
(identifier_pool) identifier_pool
)return_statement
)block
(except_clause
(as_pattern
(attribute
(identifier_asyncio) identifier_asyncio
(identifier_TimeoutError) identifier_TimeoutError
)attribute
(as_pattern_target
(identifier_err) identifier_err
)as_pattern_target
)as_pattern
(block
(expression_statement
(call
(attribute
(identifier_sentinel_logger) identifier_sentinel_logger
(identifier_debug) identifier_debug
)attribute
(argument_list
(string_"Failed to connect to Sentinel(%r) within %ss timeout") string_"Failed to connect to Sentinel(%r) within %ss timeout"
(identifier_address) identifier_address
(identifier_timeout) identifier_timeout
)argument_list
)call
)expression_statement
(return_statement
(identifier_err) identifier_err
)return_statement
)block
)except_clause
(except_clause
(as_pattern
(identifier_Exception) identifier_Exception
(as_pattern_target
(identifier_err) identifier_err
)as_pattern_target
)as_pattern
(block
(expression_statement
(call
(attribute
(identifier_sentinel_logger) identifier_sentinel_logger
(identifier_debug) identifier_debug
)attribute
(argument_list
(string_"Error connecting to Sentinel(%r): %r") string_"Error connecting to Sentinel(%r): %r"
(identifier_address) identifier_address
(identifier_err) identifier_err
)argument_list
)call
)expression_statement
(return_statement
(identifier_err) identifier_err
)return_statement
)block
)except_clause
)try_statement
)block
)function_definition
)module | Try to connect to specified Sentinel returning either
connections pool or exception. |
(module
(function_definition
(function_name_calculate_size) function_name_calculate_size
(parameters
(identifier_self) identifier_self
(identifier_modules_per_line) identifier_modules_per_line
(identifier_number_of_lines) identifier_number_of_lines
(default_parameter
(identifier_dpi) identifier_dpi
(integer_300) integer_300
)default_parameter
)parameters
(block
(expression_statement
(assignment
(identifier_width) identifier_width
(binary_operator
(binary_operator
(integer_2) integer_2
(attribute
(identifier_self) identifier_self
(identifier_quiet_zone) identifier_quiet_zone
)attribute
)binary_operator
(binary_operator
(identifier_modules_per_line) identifier_modules_per_line
(attribute
(identifier_self) identifier_self
(identifier_module_width) identifier_module_width
)attribute
)binary_operator
)binary_operator
)assignment
)expression_statement
(expression_statement
(assignment
(identifier_height) identifier_height
(binary_operator
(float_2.0) float_2.0
(binary_operator
(attribute
(identifier_self) identifier_self
(identifier_module_height) identifier_module_height
)attribute
(identifier_number_of_lines) identifier_number_of_lines
)binary_operator
)binary_operator
)assignment
)expression_statement
(if_statement
(boolean_operator
(attribute
(identifier_self) identifier_self
(identifier_font_size) identifier_font_size
)attribute
(attribute
(identifier_self) identifier_self
(identifier_text) identifier_text
)attribute
)boolean_operator
(block
(expression_statement
(augmented_assignment
(identifier_height) identifier_height
(binary_operator
(binary_operator
(call
(identifier_pt2mm) identifier_pt2mm
(argument_list
(attribute
(identifier_self) identifier_self
(identifier_font_size) identifier_font_size
)attribute
)argument_list
)call
(integer_2) integer_2
)binary_operator
(attribute
(identifier_self) identifier_self
(identifier_text_distance) identifier_text_distance
)attribute
)binary_operator
)augmented_assignment
)expression_statement
)block
)if_statement
(return_statement
(expression_list
(call
(identifier_int) identifier_int
(argument_list
(call
(identifier_mm2px) identifier_mm2px
(argument_list
(identifier_width) identifier_width
(identifier_dpi) identifier_dpi
)argument_list
)call
)argument_list
)call
(call
(identifier_int) identifier_int
(argument_list
(call
(identifier_mm2px) identifier_mm2px
(argument_list
(identifier_height) identifier_height
(identifier_dpi) identifier_dpi
)argument_list
)call
)argument_list
)call
)expression_list
)return_statement
)block
)function_definition
)module | Calculates the size of the barcode in pixel.
:parameters:
modules_per_line : Integer
Number of modules in one line.
number_of_lines : Integer
Number of lines of the barcode.
dpi : Integer
DPI to calculate.
:returns: Width and height of the barcode in pixel.
:rtype: Tuple |
(module
(function_definition
(function_name_menu_text) function_name_menu_text
(parameters
(identifier_self) identifier_self
(default_parameter
(identifier_request) identifier_request
(None) None
)default_parameter
)parameters
(block
(expression_statement
(assignment
(identifier_source_field_name) identifier_source_field_name
(attribute
(identifier_settings) identifier_settings
(identifier_PAGE_FIELD_FOR_MENU_ITEM_TEXT) identifier_PAGE_FIELD_FOR_MENU_ITEM_TEXT
)attribute
)assignment
)expression_statement
(if_statement
(parenthesized_expression
(boolean_operator
(comparison_operator
(identifier_source_field_name) identifier_source_field_name
(string_'menu_text') string_'menu_text'
)comparison_operator
(call
(identifier_hasattr) identifier_hasattr
(argument_list
(identifier_self) identifier_self
(identifier_source_field_name) identifier_source_field_name
)argument_list
)call
)boolean_operator
)parenthesized_expression
(block
(return_statement
(call
(identifier_getattr) identifier_getattr
(argument_list
(identifier_self) identifier_self
(identifier_source_field_name) identifier_source_field_name
)argument_list
)call
)return_statement
)block
)if_statement
(return_statement
(attribute
(identifier_self) identifier_self
(identifier_title) identifier_title
)attribute
)return_statement
)block
)function_definition
)module | Return a string to use as link text when this page appears in
menus. |
(module
(function_definition
(function_name_discover) function_name_discover
(parameters
(identifier_package) identifier_package
(identifier_cls_match_func) identifier_cls_match_func
)parameters
(block
(expression_statement
(assignment
(identifier_matched_classes) identifier_matched_classes
(call
(identifier_set) identifier_set
(argument_list
)argument_list
)call
)assignment
)expression_statement
(for_statement
(pattern_list
(identifier__) identifier__
(identifier_module_name) identifier_module_name
(identifier__) identifier__
)pattern_list
(call
(attribute
(identifier_pkgutil) identifier_pkgutil
(identifier_walk_packages) identifier_walk_packages
)attribute
(argument_list
(attribute
(identifier_package) identifier_package
(identifier___path__) identifier___path__
)attribute
(keyword_argument
(identifier_prefix) identifier_prefix
(binary_operator
(attribute
(identifier_package) identifier_package
(identifier___name__) identifier___name__
)attribute
(string_'.') string_'.'
)binary_operator
)keyword_argument
)argument_list
)call
(block
(expression_statement
(assignment
(identifier_module) identifier_module
(call
(identifier___import__) identifier___import__
(argument_list
(identifier_module_name) identifier_module_name
(keyword_argument
(identifier_fromlist) identifier_fromlist
(list
(call
(identifier_str) identifier_str
(argument_list
(string_'__trash') string_'__trash'
)argument_list
)call
)list
)keyword_argument
(keyword_argument
(identifier_level) identifier_level
(integer_0) integer_0
)keyword_argument
)argument_list
)call
)assignment
)expression_statement
(for_statement
(pattern_list
(identifier__) identifier__
(identifier_imported_class) identifier_imported_class
)pattern_list
(call
(attribute
(identifier_inspect) identifier_inspect
(identifier_getmembers) identifier_getmembers
)attribute
(argument_list
(identifier_module) identifier_module
(attribute
(identifier_inspect) identifier_inspect
(identifier_isclass) identifier_isclass
)attribute
)argument_list
)call
(block
(if_statement
(comparison_operator
(attribute
(identifier_imported_class) identifier_imported_class
(identifier___module__) identifier___module__
)attribute
(attribute
(identifier_module) identifier_module
(identifier___name__) identifier___name__
)attribute
)comparison_operator
(block
(continue_statement
)continue_statement
)block
)if_statement
(if_statement
(call
(identifier_cls_match_func) identifier_cls_match_func
(argument_list
(identifier_imported_class) identifier_imported_class
)argument_list
)call
(block
(expression_statement
(call
(attribute
(identifier_matched_classes) identifier_matched_classes
(identifier_add) identifier_add
)attribute
(argument_list
(identifier_imported_class) identifier_imported_class
)argument_list
)call
)expression_statement
)block
)if_statement
)block
)for_statement
)block
)for_statement
(return_statement
(identifier_matched_classes) identifier_matched_classes
)return_statement
)block
)function_definition
)module | Returns a set of classes in the directory matched by cls_match_func
Args:
path - A Python package
cls_match_func - Function taking a class and returning true if the
class is to be included in the output. |
(module
(function_definition
(function_name_addif) function_name_addif
(parameters
(identifier_self) identifier_self
(identifier_iname) identifier_iname
)parameters
(block
(expression_statement
(call
(identifier__runshell) identifier__runshell
(argument_list
(list
(identifier_brctlexe) identifier_brctlexe
(string_'addif') string_'addif'
(attribute
(identifier_self) identifier_self
(identifier_name) identifier_name
)attribute
(identifier_iname) identifier_iname
)list
(binary_operator
(string_"Could not add interface %s to %s.") string_"Could not add interface %s to %s."
(tuple
(identifier_iname) identifier_iname
(attribute
(identifier_self) identifier_self
(identifier_name) identifier_name
)attribute
)tuple
)binary_operator
)argument_list
)call
)expression_statement
)block
)function_definition
)module | Add an interface to the bridge |
(module
(function_definition
(function_name_repeats) function_name_repeats
(parameters
(identifier_seq) identifier_seq
(identifier_size) identifier_size
)parameters
(block
(expression_statement
(assignment
(identifier_seq) identifier_seq
(call
(identifier_str) identifier_str
(argument_list
(identifier_seq) identifier_seq
)argument_list
)call
)assignment
)expression_statement
(expression_statement
(assignment
(identifier_n_mers) identifier_n_mers
(list_comprehension
(subscript
(identifier_seq) identifier_seq
(slice
(identifier_i) identifier_i
(colon) colon
(binary_operator
(identifier_i) identifier_i
(identifier_size) identifier_size
)binary_operator
)slice
)subscript
(for_in_clause
(identifier_i) identifier_i
(call
(identifier_range) identifier_range
(argument_list
(binary_operator
(binary_operator
(call
(identifier_len) identifier_len
(argument_list
(identifier_seq) identifier_seq
)argument_list
)call
(identifier_size) identifier_size
)binary_operator
(integer_1) integer_1
)binary_operator
)argument_list
)call
)for_in_clause
)list_comprehension
)assignment
)expression_statement
(expression_statement
(assignment
(identifier_counted) identifier_counted
(call
(identifier_Counter) identifier_Counter
(argument_list
(identifier_n_mers) identifier_n_mers
)argument_list
)call
)assignment
)expression_statement
(expression_statement
(assignment
(identifier_found_repeats) identifier_found_repeats
(list_comprehension
(tuple
(identifier_key) identifier_key
(identifier_value) identifier_value
)tuple
(for_in_clause
(pattern_list
(identifier_key) identifier_key
(identifier_value) identifier_value
)pattern_list
(call
(attribute
(identifier_counted) identifier_counted
(identifier_iteritems) identifier_iteritems
)attribute
(argument_list
)argument_list
)call
)for_in_clause
(if_clause
(comparison_operator
(identifier_value) identifier_value
(integer_1) integer_1
)comparison_operator
)if_clause
)list_comprehension
)assignment
)expression_statement
(return_statement
(identifier_found_repeats) identifier_found_repeats
)return_statement
)block
)function_definition
)module | Count times that a sequence of a certain size is repeated.
:param seq: Input sequence.
:type seq: coral.DNA or coral.RNA
:param size: Size of the repeat to count.
:type size: int
:returns: Occurrences of repeats and how many
:rtype: tuple of the matched sequence and how many times it occurs |
(module
(function_definition
(function_name_make) function_name_make
(parameters
(default_parameter
(identifier_target) identifier_target
(string_"all") string_"all"
)default_parameter
(default_parameter
(identifier_dir) identifier_dir
(string_".") string_"."
)default_parameter
(dictionary_splat_pattern
(identifier_kwargs) identifier_kwargs
)dictionary_splat_pattern
)parameters
(block
(if_statement
(not_operator
(call
(attribute
(identifier_fs) identifier_fs
(identifier_isfile) identifier_isfile
)attribute
(argument_list
(call
(attribute
(identifier_fs) identifier_fs
(identifier_path) identifier_path
)attribute
(argument_list
(identifier_dir) identifier_dir
(string_"Makefile") string_"Makefile"
)argument_list
)call
)argument_list
)call
)not_operator
(block
(raise_statement
(call
(identifier_NoMakefileError) identifier_NoMakefileError
(argument_list
(call
(attribute
(string_"No makefile in '{}'") string_"No makefile in '{}'"
(identifier_format) identifier_format
)attribute
(argument_list
(call
(attribute
(identifier_fs) identifier_fs
(identifier_abspath) identifier_abspath
)attribute
(argument_list
(identifier_dir) identifier_dir
)argument_list
)call
)argument_list
)call
)argument_list
)call
)raise_statement
)block
)if_statement
(expression_statement
(call
(attribute
(identifier_fs) identifier_fs
(identifier_cd) identifier_cd
)attribute
(argument_list
(identifier_dir) identifier_dir
)argument_list
)call
)expression_statement
(if_statement
(comparison_operator
(string_"timeout") string_"timeout"
(identifier_kwargs) identifier_kwargs
)comparison_operator
(block
(expression_statement
(assignment
(subscript
(identifier_kwargs) identifier_kwargs
(string_"timeout") string_"timeout"
)subscript
(integer_300) integer_300
)assignment
)expression_statement
)block
)if_statement
(expression_statement
(assignment
(pattern_list
(identifier_ret) identifier_ret
(identifier_out) identifier_out
(identifier_err) identifier_err
)pattern_list
(call
(attribute
(identifier_system) identifier_system
(identifier_run) identifier_run
)attribute
(argument_list
(list
(string_"make") string_"make"
(identifier_target) identifier_target
)list
(dictionary_splat
(identifier_kwargs) identifier_kwargs
)dictionary_splat
)argument_list
)call
)assignment
)expression_statement
(expression_statement
(call
(attribute
(identifier_fs) identifier_fs
(identifier_cdpop) identifier_cdpop
)attribute
(argument_list
)argument_list
)call
)expression_statement
(if_statement
(comparison_operator
(identifier_ret) identifier_ret
(integer_0) integer_0
)comparison_operator
(block
(if_statement
(call
(attribute
(identifier_re) identifier_re
(identifier_search) identifier_search
)attribute
(argument_list
(identifier__BAD_TARGET_RE) identifier__BAD_TARGET_RE
(identifier_err) identifier_err
)argument_list
)call
(block
(raise_statement
(call
(identifier_NoTargetError) identifier_NoTargetError
(argument_list
(call
(attribute
(string_"No rule for target '{}'") string_"No rule for target '{}'"
(identifier_format) identifier_format
)attribute
(argument_list
(identifier_target) identifier_target
)argument_list
)call
)argument_list
)call
)raise_statement
)block
(else_clause
(block
(raise_statement
(call
(identifier_MakeError) identifier_MakeError
(argument_list
(call
(attribute
(string_"Target '{}' failed") string_"Target '{}' failed"
(identifier_format) identifier_format
)attribute
(argument_list
(identifier_target) identifier_target
)argument_list
)call
)argument_list
)call
)raise_statement
)block
)else_clause
)if_statement
(raise_statement
(call
(identifier_MakeError) identifier_MakeError
(argument_list
(string_"Failed") string_"Failed"
)argument_list
)call
)raise_statement
)block
)if_statement
(return_statement
(expression_list
(identifier_ret) identifier_ret
(identifier_out) identifier_out
(identifier_err) identifier_err
)expression_list
)return_statement
)block
)function_definition
)module | Run make.
Arguments:
target (str, optional): Name of the target to build. Defaults
to "all".
dir (str, optional): Path to directory containing Makefile.
**kwargs (optional): Any additional arguments to be passed to
system.run().
Returns:
(int, str, str): The first element is the return code of the
make command. The second and third elements are the stdout
and stderr of the process.
Raises:
NoMakefileError: In case a Makefile is not found in the target
directory.
NoTargetError: In case the Makefile does not support the
requested target.
MakeError: In case the target rule fails. |
(module
(function_definition
(function_name_certify_bool) function_name_certify_bool
(parameters
(identifier_value) identifier_value
(default_parameter
(identifier_required) identifier_required
(True) True
)default_parameter
)parameters
(block
(if_statement
(call
(identifier_certify_required) identifier_certify_required
(argument_list
(keyword_argument
(identifier_value) identifier_value
(identifier_value) identifier_value
)keyword_argument
(keyword_argument
(identifier_required) identifier_required
(identifier_required) identifier_required
)keyword_argument
)argument_list
)call
(block
(return_statement
)return_statement
)block
)if_statement
(if_statement
(not_operator
(call
(identifier_isinstance) identifier_isinstance
(argument_list
(identifier_value) identifier_value
(identifier_bool) identifier_bool
)argument_list
)call
)not_operator
(block
(raise_statement
(call
(identifier_CertifierTypeError) identifier_CertifierTypeError
(argument_list
(keyword_argument
(identifier_message) identifier_message
(call
(attribute
(string_"expected bool, but value is of type {cls!r}") string_"expected bool, but value is of type {cls!r}"
(identifier_format) identifier_format
)attribute
(argument_list
(keyword_argument
(identifier_cls) identifier_cls
(attribute
(attribute
(identifier_value) identifier_value
(identifier___class__) identifier___class__
)attribute
(identifier___name__) identifier___name__
)attribute
)keyword_argument
)argument_list
)call
)keyword_argument
(keyword_argument
(identifier_value) identifier_value
(identifier_value) identifier_value
)keyword_argument
(keyword_argument
(identifier_required) identifier_required
(identifier_required) identifier_required
)keyword_argument
)argument_list
)call
)raise_statement
)block
)if_statement
)block
)function_definition
)module | Certifier for boolean values.
:param value:
The value to be certified.
:param bool required:
Whether the value can be `None`. Defaults to True.
:raises CertifierTypeError:
The type is invalid |
(module
(function_definition
(function_name_batch_iter) function_name_batch_iter
(parameters
(identifier_iterator) identifier_iterator
(identifier_batch_size) identifier_batch_size
(default_parameter
(identifier_return_func) identifier_return_func
(None) None
)default_parameter
(default_parameter
(identifier_padding) identifier_padding
(None) None
)default_parameter
)parameters
(block
(for_statement
(identifier_batch) identifier_batch
(call
(identifier_zip_longest) identifier_zip_longest
(argument_list
(list_splat
(binary_operator
(list
(call
(identifier_iter) identifier_iter
(argument_list
(identifier_iterator) identifier_iterator
)argument_list
)call
)list
(identifier_batch_size) identifier_batch_size
)binary_operator
)list_splat
(keyword_argument
(identifier_fillvalue) identifier_fillvalue
(identifier_padding) identifier_padding
)keyword_argument
)argument_list
)call
(block
(expression_statement
(assignment
(identifier_gen) identifier_gen
(generator_expression
(identifier_thing) identifier_thing
(for_in_clause
(identifier_thing) identifier_thing
(identifier_batch) identifier_batch
)for_in_clause
(if_clause
(comparison_operator
(identifier_thing) identifier_thing
(identifier_padding) identifier_padding
)comparison_operator
)if_clause
)generator_expression
)assignment
)expression_statement
(if_statement
(comparison_operator
(identifier_return_func) identifier_return_func
(None) None
)comparison_operator
(block
(expression_statement
(yield
(identifier_gen) identifier_gen
)yield
)expression_statement
)block
(else_clause
(block
(expression_statement
(yield
(call
(identifier_return_func) identifier_return_func
(argument_list
(identifier_gen) identifier_gen
)argument_list
)call
)yield
)expression_statement
)block
)else_clause
)if_statement
)block
)for_statement
)block
)function_definition
)module | Break an iterable into batches of size batch_size
Note that `padding` should be set to something (anything) which is NOT a
valid member of the iterator. For example, None works for [0,1,2,...10], but
not for ['a', None, 'c', 'd'].
Parameters
----------
iterator : iterable
A python object which is iterable.
batch_size : int
The size of batches you wish to produce from the iterator.
return_func : executable or None
Pass a function that takes a generator and returns an iterable (e.g.
`list` or `set`). If None, a generator will be returned.
padding : anything
This is used internally to ensure that the remainder of the list is
included. This MUST NOT be a valid element of the iterator.
Returns
-------
An iterator over lists or generators, depending on `return_lists`. |
(module
(function_definition
(function_name_parse_peddy_sexcheck) function_name_parse_peddy_sexcheck
(parameters
(typed_parameter
(identifier_handle) identifier_handle
(type
(identifier_TextIO) identifier_TextIO
)type
)typed_parameter
)parameters
(block
(expression_statement
(assignment
(identifier_data) identifier_data
(dictionary
)dictionary
)assignment
)expression_statement
(expression_statement
(assignment
(identifier_samples) identifier_samples
(call
(attribute
(identifier_csv) identifier_csv
(identifier_DictReader) identifier_DictReader
)attribute
(argument_list
(identifier_handle) identifier_handle
)argument_list
)call
)assignment
)expression_statement
(for_statement
(identifier_sample) identifier_sample
(identifier_samples) identifier_samples
(block
(expression_statement
(assignment
(subscript
(identifier_data) identifier_data
(subscript
(identifier_sample) identifier_sample
(string_'sample_id') string_'sample_id'
)subscript
)subscript
(dictionary
(pair
(string_'predicted_sex') string_'predicted_sex'
(subscript
(identifier_sample) identifier_sample
(string_'predicted_sex') string_'predicted_sex'
)subscript
)pair
(pair
(string_'het_ratio') string_'het_ratio'
(call
(identifier_float) identifier_float
(argument_list
(subscript
(identifier_sample) identifier_sample
(string_'het_ratio') string_'het_ratio'
)subscript
)argument_list
)call
)pair
(pair
(string_'error') string_'error'
(conditional_expression
(True) True
(comparison_operator
(subscript
(identifier_sample) identifier_sample
(string_'error') string_'error'
)subscript
(string_'True') string_'True'
)comparison_operator
(False) False
)conditional_expression
)pair
)dictionary
)assignment
)expression_statement
)block
)for_statement
(return_statement
(identifier_data) identifier_data
)return_statement
)block
)function_definition
)module | Parse Peddy sexcheck output. |
(module
(function_definition
(function_name_get_string_camel_patterns) function_name_get_string_camel_patterns
(parameters
(identifier_cls) identifier_cls
(identifier_name) identifier_name
(default_parameter
(identifier_min_length) identifier_min_length
(integer_0) integer_0
)default_parameter
)parameters
(block
(expression_statement
(assignment
(identifier_patterns) identifier_patterns
(list
)list
)assignment
)expression_statement
(expression_statement
(assignment
(identifier_abbreviations) identifier_abbreviations
(call
(identifier_list) identifier_list
(argument_list
(call
(identifier_set) identifier_set
(argument_list
(call
(attribute
(identifier_cls) identifier_cls
(identifier__get_abbreviations) identifier__get_abbreviations
)attribute
(argument_list
(identifier_name) identifier_name
(keyword_argument
(identifier_output_length) identifier_output_length
(identifier_min_length) identifier_min_length
)keyword_argument
)argument_list
)call
)argument_list
)call
)argument_list
)call
)assignment
)expression_statement
(expression_statement
(call
(attribute
(identifier_abbreviations) identifier_abbreviations
(identifier_sort) identifier_sort
)attribute
(argument_list
(keyword_argument
(identifier_key) identifier_key
(identifier_len) identifier_len
)keyword_argument
(keyword_argument
(identifier_reverse) identifier_reverse
(True) True
)keyword_argument
)argument_list
)call
)expression_statement
(for_statement
(identifier_abbr) identifier_abbr
(identifier_abbreviations) identifier_abbreviations
(block
(expression_statement
(assignment
(identifier_casing_permutations) identifier_casing_permutations
(call
(identifier_list) identifier_list
(argument_list
(call
(identifier_set) identifier_set
(argument_list
(call
(attribute
(identifier_cls) identifier_cls
(identifier__get_casing_permutations) identifier__get_casing_permutations
)attribute
(argument_list
(identifier_abbr) identifier_abbr
)argument_list
)call
)argument_list
)call
)argument_list
)call
)assignment
)expression_statement
(expression_statement
(call
(attribute
(identifier_casing_permutations) identifier_casing_permutations
(identifier_sort) identifier_sort
)attribute
(argument_list
(keyword_argument
(identifier_key) identifier_key
(lambda
(lambda_parameters
(identifier_v) identifier_v
)lambda_parameters
(tuple
(call
(attribute
(identifier_v) identifier_v
(identifier_upper) identifier_upper
)attribute
(argument_list
)argument_list
)call
(call
(attribute
(subscript
(identifier_v) identifier_v
(integer_0) integer_0
)subscript
(identifier_islower) identifier_islower
)attribute
(argument_list
)argument_list
)call
(call
(identifier_len) identifier_len
(argument_list
(identifier_v) identifier_v
)argument_list
)call
)tuple
)lambda
)keyword_argument
)argument_list
)call
)expression_statement
(expression_statement
(assignment
(identifier_permutations) identifier_permutations
(list_comprehension
(identifier_permutation) identifier_permutation
(for_in_clause
(identifier_permutation) identifier_permutation
(identifier_casing_permutations) identifier_casing_permutations
)for_in_clause
(if_clause
(boolean_operator
(call
(attribute
(identifier_cls) identifier_cls
(identifier_is_valid_camel) identifier_is_valid_camel
)attribute
(argument_list
(identifier_permutation) identifier_permutation
)argument_list
)call
(comparison_operator
(call
(identifier_len) identifier_len
(argument_list
(identifier_permutation) identifier_permutation
)argument_list
)call
(integer_2) integer_2
)comparison_operator
)boolean_operator
)if_clause
)list_comprehension
)assignment
)expression_statement
(if_statement
(identifier_permutations) identifier_permutations
(block
(expression_statement
(call
(attribute
(identifier_patterns) identifier_patterns
(identifier_append) identifier_append
)attribute
(argument_list
(identifier_permutations) identifier_permutations
)argument_list
)call
)expression_statement
)block
)if_statement
)block
)for_statement
(return_statement
(identifier_patterns) identifier_patterns
)return_statement
)block
)function_definition
)module | Finds all permutations of possible camel casing of the given name
:param name: str, the name we need to get all possible permutations and abbreviations for
:param min_length: int, minimum length we want for abbreviations
:return: list(list(str)), list casing permutations of list of abbreviations |
(module
(function_definition
(function_name_ensure_dim) function_name_ensure_dim
(parameters
(identifier_core) identifier_core
(identifier_dim) identifier_dim
(identifier_dim_) identifier_dim_
)parameters
(block
(if_statement
(comparison_operator
(identifier_dim) identifier_dim
(None) None
)comparison_operator
(block
(expression_statement
(assignment
(identifier_dim) identifier_dim
(identifier_dim_) identifier_dim_
)assignment
)expression_statement
)block
)if_statement
(if_statement
(not_operator
(identifier_dim) identifier_dim
)not_operator
(block
(return_statement
(expression_list
(identifier_core) identifier_core
(integer_1) integer_1
)expression_list
)return_statement
)block
)if_statement
(if_statement
(comparison_operator
(identifier_dim_) identifier_dim_
(identifier_dim) identifier_dim
)comparison_operator
(block
(return_statement
(expression_list
(identifier_core) identifier_core
(call
(identifier_int) identifier_int
(argument_list
(identifier_dim) identifier_dim
)argument_list
)call
)expression_list
)return_statement
)block
)if_statement
(if_statement
(comparison_operator
(identifier_dim) identifier_dim
(identifier_dim_) identifier_dim_
)comparison_operator
(block
(expression_statement
(assignment
(identifier_key_convert) identifier_key_convert
(lambda
(lambda_parameters
(identifier_vari) identifier_vari
)lambda_parameters
(subscript
(identifier_vari) identifier_vari
(slice
(colon) colon
(identifier_dim_) identifier_dim_
)slice
)subscript
)lambda
)assignment
)expression_statement
)block
(else_clause
(block
(expression_statement
(assignment
(identifier_key_convert) identifier_key_convert
(lambda
(lambda_parameters
(identifier_vari) identifier_vari
)lambda_parameters
(binary_operator
(identifier_vari) identifier_vari
(binary_operator
(tuple
(integer_0) integer_0
)tuple
(parenthesized_expression
(binary_operator
(identifier_dim) identifier_dim
(identifier_dim_) identifier_dim_
)binary_operator
)parenthesized_expression
)binary_operator
)binary_operator
)lambda
)assignment
)expression_statement
)block
)else_clause
)if_statement
(expression_statement
(assignment
(identifier_new_core) identifier_new_core
(dictionary
)dictionary
)assignment
)expression_statement
(for_statement
(pattern_list
(identifier_key) identifier_key
(identifier_val) identifier_val
)pattern_list
(call
(attribute
(identifier_core) identifier_core
(identifier_items) identifier_items
)attribute
(argument_list
)argument_list
)call
(block
(expression_statement
(assignment
(identifier_key_) identifier_key_
(call
(identifier_key_convert) identifier_key_convert
(argument_list
(identifier_key) identifier_key
)argument_list
)call
)assignment
)expression_statement
(if_statement
(comparison_operator
(identifier_key_) identifier_key_
(identifier_new_core) identifier_new_core
)comparison_operator
(block
(expression_statement
(augmented_assignment
(subscript
(identifier_new_core) identifier_new_core
(identifier_key_) identifier_key_
)subscript
(identifier_val) identifier_val
)augmented_assignment
)expression_statement
)block
(else_clause
(block
(expression_statement
(assignment
(subscript
(identifier_new_core) identifier_new_core
(identifier_key_) identifier_key_
)subscript
(identifier_val) identifier_val
)assignment
)expression_statement
)block
)else_clause
)if_statement
)block
)for_statement
(return_statement
(expression_list
(identifier_new_core) identifier_new_core
(call
(identifier_int) identifier_int
(argument_list
(identifier_dim) identifier_dim
)argument_list
)call
)expression_list
)return_statement
)block
)function_definition
)module | Ensure that dim is correct. |
(module
(function_definition
(function_name_extern_call) function_name_extern_call
(parameters
(identifier_self) identifier_self
(identifier_context_handle) identifier_context_handle
(identifier_func) identifier_func
(identifier_args_ptr) identifier_args_ptr
(identifier_args_len) identifier_args_len
)parameters
(block
(expression_statement
(assignment
(identifier_c) identifier_c
(call
(attribute
(attribute
(identifier_self) identifier_self
(identifier__ffi) identifier__ffi
)attribute
(identifier_from_handle) identifier_from_handle
)attribute
(argument_list
(identifier_context_handle) identifier_context_handle
)argument_list
)call
)assignment
)expression_statement
(expression_statement
(assignment
(identifier_runnable) identifier_runnable
(call
(attribute
(identifier_c) identifier_c
(identifier_from_value) identifier_from_value
)attribute
(argument_list
(subscript
(identifier_func) identifier_func
(integer_0) integer_0
)subscript
)argument_list
)call
)assignment
)expression_statement
(expression_statement
(assignment
(identifier_args) identifier_args
(call
(identifier_tuple) identifier_tuple
(generator_expression
(call
(attribute
(identifier_c) identifier_c
(identifier_from_value) identifier_from_value
)attribute
(argument_list
(subscript
(identifier_arg) identifier_arg
(integer_0) integer_0
)subscript
)argument_list
)call
(for_in_clause
(identifier_arg) identifier_arg
(call
(attribute
(attribute
(identifier_self) identifier_self
(identifier__ffi) identifier__ffi
)attribute
(identifier_unpack) identifier_unpack
)attribute
(argument_list
(identifier_args_ptr) identifier_args_ptr
(identifier_args_len) identifier_args_len
)argument_list
)call
)for_in_clause
)generator_expression
)call
)assignment
)expression_statement
(return_statement
(call
(attribute
(identifier_self) identifier_self
(identifier_call) identifier_call
)attribute
(argument_list
(identifier_c) identifier_c
(identifier_runnable) identifier_runnable
(identifier_args) identifier_args
)argument_list
)call
)return_statement
)block
)function_definition
)module | Given a callable, call it. |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.