def
Func
(
arg_0
)
:
arg_1
=
arg_0
.
split
(
)
try
:
arg_2
=
arg_1
[
0
]
arg_3
=
int
(
arg_1
[
1
]
)
arg_4
=
int
(
arg_1
[
2
]
)
arg_5
=
arg_1
[
3
]
except
(
IndexError
,
ValueError
)
:
raise
ValueError
(
"Invalid newsgroup info"
)
return
arg_2
,
arg_3
,
arg_4
,
arg_5

def Func(arg_0):
    """Parse a newsgroup info line to python types.

    Args:
        line: An info response line containing newsgroup info.

    Returns:
        A tuple of group name, low-water as integer, high-water as integer and
        posting status.

    Raises:
        ValueError: If the newsgroup info cannot be parsed.

    Note:
        Posting status is a character is one of (but not limited to):
            "y" posting allowed
            "n" posting not allowed
            "m" posting is moderated
    """
    arg_1 = arg_0.split()
    try:
        arg_2 = arg_1[0]
        arg_3 = int(arg_1[1])
        arg_4 = int(arg_1[2])
        arg_5 = arg_1[3]
    except (IndexError, ValueError):
        raise ValueError("Invalid newsgroup info")
    return arg_2, arg_3, arg_4, arg_5

Parse a newsgroup info line to python types .


def Func ( arg_0 ) : arg_1 = str ( arg_0 ) if arg_0 . respbody is not None : arg_1 += '\n' + arg_0 . respbody . decode ( 'utf-8-sig' ) raise AzureHttpError ( arg_1 , arg_0 . status )

def Func(arg_0):
    ''' Simple error handler for azure.'''
    arg_1 = str(arg_0)
    if arg_0.respbody is not None:
        arg_1 += '\n' + arg_0.respbody.decode('utf-8-sig')
    raise AzureHttpError(arg_1, arg_0.status)


def Func ( ) : initLogging ( verbose = True ) initExperimentPrng ( ) @ staticmethod def _mockCreate ( * arg_0 , ** arg_1 ) : arg_1 . pop ( 'implementation' , None ) return SDRClassifierDiff ( * arg_0 , ** arg_1 ) arg_2 . create = _mockCreate runExperiment ( sys . argv [ 1 : ] )

def Func():
  """Run according to options in sys.argv and diff classifiers."""
  initLogging(verbose=True)

  # Initialize PRNGs
  initExperimentPrng()

  # Mock out the creation of the SDRClassifier.
  @staticmethod
  def _mockCreate(*arg_0, **arg_1):
    arg_1.pop('implementation', None)
    return SDRClassifierDiff(*arg_0, **arg_1)
  arg_2.create = _mockCreate

  # Run it!
  runExperiment(sys.argv[1:])

Run according to options in sys . argv and diff classifiers .


def Func(arg_0, arg_1, arg_2=None):
    """Unpack link into location.
    If download_dir is provided and link points to a file, make a copy
    of the link file inside download_dir."""

    arg_3 = url_to_path(arg_0.url_without_fragment)

    # If it's a url to a local directory
    if os.path.isdir(arg_3):
        if os.path.isdir(arg_1):
            rmtree(arg_1)
        shutil.copytree(arg_3, arg_1, symlinks=True)
        if arg_2:
            logger.info('Link is a directory, ignoring download_dir')
        return

    # if link has a hash, let's confirm it matches
    if arg_0.hash:
        arg_4 = _get_hash_from_file(arg_3, arg_0)
        _check_hash(arg_4, arg_0)

    # If a download dir is specified, is the file already there and valid?
    arg_5 = None
    if arg_2:
        arg_5 = _check_download_dir(arg_0, arg_2)

    if arg_5:
        arg_6 = arg_5
    else:
        arg_6 = arg_3

    arg_7 = mimetypes.guess_type(arg_6)[0]

    # unpack the archive to the build dir location. even when only downloading
    # archives, they have to be unpacked to parse dependencies
    unpack_file(arg_6, arg_1, arg_7, arg_0)

    # a download dir is specified and not already downloaded
    if arg_2 and not arg_5:
        _copy_file(arg_6, arg_2, arg_7, arg_0)

Unpack link into location . If download_dir is provided and link points to a file make a copy of the link file inside download_dir .


def Func ( arg_0 ) : if isinstance ( arg_0 , gym . spaces . Dict ) : assert isinstance ( arg_0 . spaces , OrderedDict ) arg_1 = arg_0 . spaces else : arg_1 = { None : arg_0 } arg_2 = [ ] arg_3 = { } arg_4 = { } for arg_5 , arg_6 in arg_1 . items ( ) : arg_2 . append ( arg_5 ) arg_3 [ arg_5 ] = arg_6 . shape arg_4 [ arg_5 ] = arg_6 . dtype return arg_2 , arg_3 , arg_4

def Func(arg_0):
    """
    Get dict-structured information about a gym.Space.

    Returns:
      A tuple (keys, shapes, dtypes):
        keys: a list of dict keys.
        shapes: a dict mapping keys to shapes.
        dtypes: a dict mapping keys to dtypes.
    """
    if isinstance(arg_0, gym.spaces.Dict):
        assert isinstance(arg_0.spaces, OrderedDict)
        arg_1 = arg_0.spaces
    else:
        arg_1 = {None: arg_0}
    arg_2 = []
    arg_3 = {}
    arg_4 = {}
    for arg_5, arg_6 in arg_1.items():
        arg_2.append(arg_5)
        arg_3[arg_5] = arg_6.shape
        arg_4[arg_5] = arg_6.dtype
    return arg_2, arg_3, arg_4

Get dict - structured information about a gym . Space .


def Func(arg_0, arg_1, arg_2):
        """
        Update a store.

        :param store_id: The store id.
        :type store_id: :py:class:`str`
        :param data: The request body parameters
        :type data: :py:class:`dict`
        """
        arg_0.store_id = arg_1
        return arg_0._mc_client._patch(url=arg_0._build_path(arg_1), arg_2=arg_2)


def Func ( arg_0 , arg_1 = [ 0 , 0.01 , 0.02 , 0.05 , 0.1 , 0.2 , 0.3 , 0.4 , 0.5 ] ) : arg_1 = to_one_dim_array ( arg_1 ) arg_2 = find_nearest_matches ( np . float32 ( arg_0 . qvalue . values ) , arg_1 ) arg_3 = arg_0 . iloc [ arg_2 ] . copy ( ) for arg_4 , ( arg_5 , arg_6 ) in enumerate ( zip ( arg_2 , arg_2 [ 1 : ] ) ) : if arg_6 == arg_5 : arg_3 . iloc [ arg_4 + 1 , : ] = None arg_3 . qvalue = arg_1 arg_3 . reset_index ( inplace = True , drop = True ) return arg_3 [ [ 'qvalue' , 'pvalue' , 'svalue' , 'pep' , 'fdr' , 'fnr' , 'fpr' , 'tp' , 'tn' , 'fp' , 'fn' , 'cutoff' ] ]

def Func(arg_0, arg_1=[0, 0.01, 0.02, 0.05, 0.1, 0.2, 0.3, 0.4, 0.5]):
    """ Summary error table for some typical q-values """

    arg_1 = to_one_dim_array(arg_1)
    # find best matching fows in df for given qvalues:
    arg_2 = find_nearest_matches(np.float32(arg_0.qvalue.values), arg_1)
    # extract sub table
    arg_3 = arg_0.iloc[arg_2].copy()
    # remove duplicate hits, mark them with None / NAN:
    for arg_4, (arg_5, arg_6) in enumerate(zip(arg_2, arg_2[1:])):
        if arg_6 == arg_5:
            arg_3.iloc[arg_4 + 1, :] = None
    # attach q values column
    arg_3.qvalue = arg_1
    # remove old index from original df:
    arg_3.reset_index(inplace=True, drop=True)
    return arg_3[['qvalue','pvalue','svalue','pep','fdr','fnr','fpr','tp','tn','fp','fn','cutoff']]

Summary error table for some typical q - values


(self, tree: list, sr: state.StateRegister)

def Func(arg_0, arg_1: arg_2, arg_3: arg_4.StateRegister):
        """ main function for creating a bottom-up tree automata
            for a block of matching statements.
        """
        arg_6 = []
        # for all statements populate a list
        # from deeper to nearer of MatchExpr instances.
        for arg_7 in arg_0.stmts:
            arg_8 = arg_2()
            arg_7.Func(arg_8)
            arg_6.append(arg_8)
        # Walk on all MatchExpr instance
        # and create State instance into the StateRegister
        arg_0.root_edge = populate_state_register(arg_6, arg_3)

main function for creating a bottom - up tree automata for a block of matching statements .


(depth_file, json_dict, cutoff, sample_id)

def Func(arg_0, arg_1, arg_2, arg_3):
    """
    Function that handles the inputs required to parse depth files from bowtie
    and dumps a dict to a json file that can be imported into pATLAS.

    Parameters
    ----------
    depth_file: str
         the path to depth file for each sample
    json_dict: str
        the file that contains the dictionary with keys and values for
        accessions
        and their respective lengths
    cutoff: str
        the cutoff used to trim the unwanted matches for the minimum coverage
        results from mapping. This value may range between 0 and 1.
    sample_id: str
        the id of the sample being parsed

    """

    # check for the appropriate value for the cutoff value for coverage results
    logger.debug("Cutoff value: {}. Type: {}".format(arg_2, type(arg_2)))
    try:
        arg_4 = float(arg_2)
        if arg_4 < 0.4:
            logger.warning("This cutoff value will generate a high volume of "
                           "plot data. Therefore '.report.json' can be too big")
    except ValueError:
        logger.error("Cutoff value should be a string such as: '0.6'. "
                     "The outputted value: {}. Make sure to provide an "
                     "appropriate value for --cov_cutoff".format(arg_2))
        sys.exit(1)

    # loads dict from file, this file is provided in docker image

    arg_5 = json.load(open(arg_1))
    if arg_5:
        logger.info("Loaded dictionary of plasmid lengths")
    else:
        logger.error("Something went wrong and plasmid lengths dictionary"
                     "could not be loaded. Check if process received this"
                     "param successfully.")
        sys.exit(1)

    # read depth file
    arg_6 = open(arg_0)

    # first reads the depth file and generates dictionaries to handle the input
    # to a simpler format
    logger.info("Reading depth file and creating dictionary to dump.")
    arg_7 = depth_file_reader(arg_6)
    arg_8, arg_9 = generate_jsons(arg_7,
                                                        arg_5,
                                                        arg_4)

    if arg_8 and arg_9:
        logger.info("percentage_bases_covered length: {}".format(
            str(len(arg_8))))
        logger.info("dict_cov length: {}".format(str(len(arg_9))))
    else:
        logger.error("Both dicts that dump to JSON file or .report.json are "
                     "empty.")

    # then dump do file
    logger.info("Dumping to {}".format("{}_mapping.json".format(arg_0)))
    with open("{}_mapping.json".format(arg_0), "w") as output_json:
        output_json.write(json.dumps(arg_8))

    arg_10 = {
        "tableRow": [{
            "sample": arg_3,
            "data": [{
                "header": "Mapping",
                "table": "plasmids",
                "patlas_mapping": arg_8,
                "value": len(arg_8)
            }]
        }],
        "sample": arg_3,
        "patlas_mapping": arg_8,
        "plotData": [{
            "sample": arg_3,
            "data": {
                "patlasMappingSliding": arg_9
            },
        }]
    }

    logger.debug("Size of dict_cov: {} kb".format(asizeof(arg_10)/1024))
    logger.info("Writing to .report.json")
    with open(".report.json", "w") as json_report:
        json_report.write(json.dumps(arg_10, separators=(",", ":")))

Function that handles the inputs required to parse depth files from bowtie and dumps a dict to a json file that can be imported into pATLAS .


def
Func
(
arg_0
,
arg_1
)
:
if
not
isinstance
(
arg_0
,
list
)
:
raise
ParseError
(
'ListValue must be in [] which is {0}.'
.
format
(
arg_0
)
)
arg_1
.
ClearField
(
'values'
)
for
arg_2
in
arg_0
:
_ConvertValueMessage
(
arg_2
,
arg_1
.
values
.
add
(
)
)

def Func(arg_0, arg_1):
  """Convert a JSON representation into ListValue message."""
  if not isinstance(arg_0, list):
    raise ParseError(
        'ListValue must be in [] which is {0}.'.format(arg_0))
  arg_1.ClearField('values')
  for arg_2 in arg_0:
    _ConvertValueMessage(arg_2, arg_1.values.add())

Convert a JSON representation into ListValue message .


def Func(arg_0):
        ''' Initialize the dictionary of architectures for disassembling via capstone'''

        return {
            ARM32:   (CS_ARCH_ARM,   CS_MODE_ARM),
            ARM64:   (CS_ARCH_ARM64, CS_MODE_LITTLE_ENDIAN),
            ARM_TB:  (CS_ARCH_ARM,   CS_MODE_THUMB),
            MIPS32:  (CS_ARCH_MIPS,  CS_MODE_MIPS32),
            MIPS64:  (CS_ARCH_MIPS,  CS_MODE_MIPS64),
            SPARC32: (CS_ARCH_SPARC, CS_MODE_BIG_ENDIAN),
            SPARC64: (CS_ARCH_SPARC, CS_MODE_V9),
            SYSTEMZ: (CS_ARCH_SYSZ,  CS_MODE_BIG_ENDIAN),
            X86_16:  (CS_ARCH_X86,   CS_MODE_16),
            X86_32:  (CS_ARCH_X86,   CS_MODE_32),
            X86_64:  (CS_ARCH_X86,   CS_MODE_64),
        }


The name of the current module if the request was dispatched
        to an actual module.  This is deprecated functionality, use blueprints
        instead.

def
Func
(
arg_0
)
:
from
warnings
import
warn
warn
(
DeprecationWarning
(
'Funcs were deprecated in favor of '
'blueprints.  Use request.blueprint '
'instead.'
)
,
stacklevel
=
2
)
if
arg_0
.
_is_old_Func
:
return
arg_0
.
blueprint

def Func(arg_0):
        """The name of the current Func if the request was dispatched
        to an actual Func.  This is deprecated functionality, use blueprints
        instead.
        """
        from warnings import warn
        warn(DeprecationWarning('Funcs were deprecated in favor of '
                                'blueprints.  Use request.blueprint '
                                'instead.'), stacklevel=2)
        if arg_0._is_old_Func:
            return arg_0.blueprint

The name of the current module if the request was dispatched to an actual module . This is deprecated functionality use blueprints instead .


def Func ( arg_0 , Func ) : arg_0 . _error = RuntimeError ( Func ) if isinstance ( Func , str ) else Func

def Func(arg_0, Func):
        """
        Defines a simulated exception error that will be raised.

        Arguments:
            error (str|Exception): error to raise.

        Returns:
            self: current Mock instance.
        """
        arg_0._error = RuntimeError(Func) if isinstance(Func, str) else Func

Defines a simulated exception error that will be raised .


def Func(arg_0, arg_1):
    """
    Func symbolic model.

    Algorithm: Walks from end of string not including NULL building ITE tree when current byte is symbolic.

    :param State state: current program state
    :param int s: Address of string
    :return: Symbolic Func result
    :rtype: Expression or int
    """

    arg_2 = arg_0.cpu

    if issymbolic(arg_1):
        raise ConcretizeArgument(arg_0.cpu, 1)

    arg_3 = _find_zero(arg_2, arg_0.constraints, arg_1)

    arg_4 = arg_3

    for arg_5 in range(arg_3 - 1, -1, -1):
        arg_6 = arg_2.read_int(arg_1 + arg_5, 8)
        if issymbolic(arg_6):
            arg_4 = ITEBV(arg_2.address_bit_size, arg_6 == 0, arg_5, arg_4)

    return arg_4

strlen symbolic model.

    Algorithm: Walks from end of string not including NULL building ITE tree when current byte is symbolic.

    :param State state: current program state
    :param int s: Address of string
    :return: Symbolic strlen result
    :rtype: Expression or int


def Func ( arg_0 ) : arg_1 = OrderedDict ( ) arg_2 = OrderedDict ( [ ( arg_0 . file , [ 'Rscript' , arg_0 . file ] + arg_0 . cmd ) , ] ) for arg_3 , arg_4 in arg_2 . items ( ) : arg_1 [ arg_3 ] = arg_0 . run_command_under_r_root ( arg_4 ) return arg_0 . decode_cmd_out ( completed_cmd = arg_1 [ arg_0 . file ] )

def Func(arg_0):
        """
        Execute R script
        """
        arg_1 = OrderedDict()
        arg_2 = OrderedDict([
            (arg_0.file, ['Rscript', arg_0.file] + arg_0.cmd),
        ])
        for arg_3, arg_4 in arg_2.items():
            arg_1[arg_3] = arg_0.run_command_under_r_root(arg_4)

        return arg_0.decode_cmd_out(completed_cmd=arg_1[arg_0.file])


def Func ( arg_0 ) : arg_1 = '' arg_2 = _player_re . search ( arg_0 . text ) if arg_2 : arg_3 = arg_2 . group ( 0 ) . replace ( '&' , '&' ) if 'hash' not in arg_3 : arg_2 = _hash_re . search ( arg_0 . text ) if arg_2 : arg_1 = arg_3 + '&hash=' + arg_2 . group ( 1 ) else : arg_1 = arg_3 return 'http://ceskatelevize.cz/' + arg_1

def Func(arg_0):
    """
    Finds embedded player url in HTTP response.

    :param response: Response object.
    :returns: Player url (str).
    """
    arg_1 = ''
    arg_2 = _player_re.search(arg_0.text)
    if arg_2:
        arg_3 = arg_2.group(0).replace('&', '&')
        if 'hash' not in arg_3:
            # there's no hash in the URL, try to find it
            arg_2 = _hash_re.search(arg_0.text)
            if arg_2:
                arg_1 = arg_3 + '&hash=' + arg_2.group(1)
        else:
            arg_1 = arg_3

    return 'http://ceskatelevize.cz/' + arg_1

Finds embedded player url in HTTP response .


def Func ( arg_0 ) : @ wraps ( arg_0 ) def wrapper ( arg_1 , * arg_2 , ** arg_3 ) : with ( yield from arg_1 . get_cursor ( _CursorType . NAMEDTUPLE ) ) as c : try : yield from c . execute ( 'BEGIN' ) arg_4 = ( yield from arg_0 ( arg_1 , c , * arg_2 , ** arg_3 ) ) except Exception : yield from c . execute ( 'ROLLBACK' ) else : yield from c . execute ( 'COMMIT' ) return arg_4 return wrapper

def Func(arg_0):
    """
    Provides a transacted cursor which will run in autocommit=false mode

    For any exception the Func will be rolled back.
    Requires that the function being decorated is an instance of a class or object
    that yields a cursor from a get_cursor(cursor_type=CursorType.NAMEDTUPLE) coroutine or provides such an object
    as the first argument in its signature

    Yields:
        A client-side transacted named cursor
    """

    @wraps(arg_0)
    def wrapper(arg_1, *arg_2, **arg_3):
        with (yield from arg_1.get_cursor(_CursorType.NAMEDTUPLE)) as c:
            try:
                yield from c.execute('BEGIN')
                arg_4 = (yield from arg_0(arg_1, c, *arg_2, **arg_3))
            except Exception:
                yield from c.execute('ROLLBACK')
            else:
                yield from c.execute('COMMIT')
                return arg_4

    return wrapper

Provides a transacted cursor which will run in autocommit=false mode

    For any exception the transaction will be rolled back.
    Requires that the function being decorated is an instance of a class or object
    that yields a cursor from a get_cursor(cursor_type=CursorType.NAMEDTUPLE) coroutine or provides such an object
    as the first argument in its signature

    Yields:
        A client-side transacted named cursor

Provides a transacted cursor which will run in autocommit = false mode


return (
            pod
            for pod in self.pods
            if pod.primary
            or pod.title == 'Result'
        )

def Func ( arg_0 ) : return ( arg_1 for arg_1 in arg_0 . pods if arg_1 . primary or arg_1 . title == 'Result' )

def Func(arg_0):
        """
        The pods that hold the response to a simple, discrete query.
        """
        return (
            arg_1
            for arg_1 in arg_0.pods
            if arg_1.primary
            or arg_1.title == 'Result'
        )

The pods that hold the response to a simple discrete query .


def
Func
(
arg_0
,
arg_1
=
'col'
)
:
arg_0
=
np
.
array
(
arg_0
)
if
arg_1
==
'col'
:
return
arg_0
.
flatten
(
order
=
'F'
)
elif
arg_1
==
'row'
:
return
arg_0
.
flatten
(
order
=
'C'
)
elif
arg_1
in
[
'pauli'
,
'pauli_weights'
]
:
arg_2
=
int
(
np
.
log2
(
len
(
arg_0
)
)
)
if
len
(
arg_0
)
!=
2
**
arg_2
:
raise
Exception
(
'Input state must be n-qubit state'
)
if
arg_1
==
'pauli_weights'
:
arg_3
=
pauli_group
(
arg_2
,
case
=
'weight'
)
else
:
arg_3
=
pauli_group
(
arg_2
,
case
=
'tensor'
)
arg_4
=
[
np
.
trace
(
np
.
dot
(
p
.
to_matrix
(
)
,
arg_0
)
)
for
p
in
arg_3
]
return
np
.
array
(
arg_4
)
return

def Func(arg_0, arg_1='col'):
    """Flatten an operator to a vector in a specified basis.

    Args:
        density_matrix (ndarray): a density matrix.
        method (str): the method of vectorization. Allowed values are
            - 'col' (default) flattens to column-major vector.
            - 'row' flattens to row-major vector.
            - 'pauli'flattens in the n-qubit Pauli basis.
            - 'pauli-weights': flattens in the n-qubit Pauli basis ordered by
               weight.

    Returns:
        ndarray: the resulting vector.
    Raises:
        Exception: if input state is not a n-qubit state
    """
    arg_0 = np.array(arg_0)
    if arg_1 == 'col':
        return arg_0.flatten(order='F')
    elif arg_1 == 'row':
        return arg_0.flatten(order='C')
    elif arg_1 in ['pauli', 'pauli_weights']:
        arg_2 = int(np.log2(len(arg_0)))  # number of qubits
        if len(arg_0) != 2**arg_2:
            raise Exception('Input state must be n-qubit state')
        if arg_1 == 'pauli_weights':
            arg_3 = pauli_group(arg_2, case='weight')
        else:
            arg_3 = pauli_group(arg_2, case='tensor')
        arg_4 = [np.trace(np.dot(p.to_matrix(), arg_0))
                for p in arg_3]
        return np.array(arg_4)
    return None

Flatten an operator to a vector in a specified basis .


def Func(arg_0, arg_1):
        '''
        Import Nodebox libraries.

        The libraries get _ctx, which provides
        them with the nodebox API.

        :param libName: Library name to import
        '''
        # from Nodebox
        arg_2 = __import__(arg_1)
        arg_0._namespace[arg_1] = arg_2
        arg_2._ctx = arg_0
        return arg_2


def Func ( arg_0 , arg_1 ) : if arg_1 <= 0 : return arg_0 if not isinstance ( arg_0 , string_types ) and hasattr ( arg_0 , '__iter__' ) : arg_2 = False else : arg_2 = True arg_0 = [ arg_0 ] arg_3 = [ ] for arg_4 in arg_0 : arg_4 = check_img ( arg_4 ) arg_5 = arg_4 . get_affine ( ) arg_6 = _smooth_data_array ( arg_4 . get_data ( ) , arg_5 , arg_1 = arg_1 , copy = True ) arg_3 . append ( nib . Nifti1Image ( arg_6 , arg_5 ) ) if arg_2 : return arg_3 [ 0 ] else : return arg_3

def Func(arg_0, arg_1):
    """Smooth images using a Gaussian filter.

    Apply a Gaussian filter along the three first dimensions of each image in images.
    In all cases, non-finite values in input are zeroed.

    Parameters
    ----------
    imgs: str or img-like object or iterable of img-like objects
        See boyle.nifti.read.read_img
        Image(s) to smooth.

    fwhm: scalar or numpy.ndarray
        Smoothing kernel size, as Full-Width at Half Maximum (FWHM) in millimeters.
        If a scalar is given, kernel width is identical on all three directions.
        A numpy.ndarray must have 3 elements, giving the FWHM along each axis.

    Returns
    -------
    Func: nibabel.Nifti1Image or list of.
        Smooth input image/s.
    """
    if arg_1 <= 0:
        return arg_0

    if not isinstance(arg_0, string_types) and hasattr(arg_0, '__iter__'):
        arg_2 = False
    else:
        arg_2 = True
        arg_0 = [arg_0]

    arg_3 = []
    for arg_4 in arg_0:
        arg_4    = check_img(arg_4)
        arg_5 = arg_4.get_affine()
        arg_6 = _smooth_data_array(arg_4.get_data(), arg_5, arg_1=arg_1, copy=True)
        arg_3.append(nib.Nifti1Image(arg_6, arg_5))

    if arg_2:
        return arg_3[0]
    else:
        return arg_3

Smooth images using a Gaussian filter.

    Apply a Gaussian filter along the three first dimensions of each image in images.
    In all cases, non-finite values in input are zeroed.

    Parameters
    ----------
    imgs: str or img-like object or iterable of img-like objects
        See boyle.nifti.read.read_img
        Image(s) to smooth.

    fwhm: scalar or numpy.ndarray
        Smoothing kernel size, as Full-Width at Half Maximum (FWHM) in millimeters.
        If a scalar is given, kernel width is identical on all three directions.
        A numpy.ndarray must have 3 elements, giving the FWHM along each axis.

    Returns
    -------
    smooth_imgs: nibabel.Nifti1Image or list of.
        Smooth input image/s.


def Func(arg_0):
    """
    This retrieves a time zone from the local zoneinfo tarball that is packaged
    with dateutil.

    :param name:
        An IANA-style time zone name, as found in the zoneinfo file.

    :return:
        Returns a :class:`dateutil.tz.tzfile` time zone object.

    .. warning::
        It is generally inadvisable to use this function, and it is only
        provided for API compatibility with earlier versions. This is *not*
        equivalent to ``dateutil.tz.Func()``, which selects an appropriate
        time zone based on the inputs, favoring system zoneinfo. This is ONLY
        for accessing the dateutil-specific zoneinfo (which may be out of
        date compared to the system zoneinfo).

    .. deprecated:: 2.6
        If you need to use a specific zoneinfofile over the system zoneinfo,
        instantiate a :class:`dateutil.zoneinfo.ZoneInfoFile` object and call
        :func:`dateutil.zoneinfo.ZoneInfoFile.get(name)` instead.

        Use :func:`get_zonefile_instance` to retrieve an instance of the
        dateutil-provided zoneinfo.
    """
    warnings.warn("zoneinfo.Func() will be removed in future versions, "
                  "to use the dateutil-provided zoneinfo files, instantiate a "
                  "ZoneInfoFile object and use ZoneInfoFile.zones.get() "
                  "instead. See the documentation for details.",
                  DeprecationWarning)

    if len(_CLASS_ZONE_INSTANCE) == 0:
        _CLASS_ZONE_INSTANCE.append(ZoneInfoFile(getzoneinfofile_stream()))
    return _CLASS_ZONE_INSTANCE[0].zones.get(arg_0)

This retrieves a time zone from the local zoneinfo tarball that is packaged
    with dateutil.

    :param name:
        An IANA-style time zone name, as found in the zoneinfo file.

    :return:
        Returns a :class:`dateutil.tz.tzfile` time zone object.

    .. warning::
        It is generally inadvisable to use this function, and it is only
        provided for API compatibility with earlier versions. This is *not*
        equivalent to ``dateutil.tz.gettz()``, which selects an appropriate
        time zone based on the inputs, favoring system zoneinfo. This is ONLY
        for accessing the dateutil-specific zoneinfo (which may be out of
        date compared to the system zoneinfo).

    .. deprecated:: 2.6
        If you need to use a specific zoneinfofile over the system zoneinfo,
        instantiate a :class:`dateutil.zoneinfo.ZoneInfoFile` object and call
        :func:`dateutil.zoneinfo.ZoneInfoFile.get(name)` instead.

        Use :func:`get_zonefile_instance` to retrieve an instance of the
        dateutil-provided zoneinfo.

This retrieves a time zone from the local zoneinfo tarball that is packaged with dateutil .


def Func(arg_0):
        """Yield layers of the multigraph."""
        arg_1 = dict()  # Dict[node, predecessors not visited]
        arg_2 = [arg_4 for arg_4 in arg_0.input_map.values()]
        yield arg_2
        arg_3 = []
        while arg_2:
            for arg_4 in arg_2:
                # Count multiedges with multiplicity.
                for arg_5 in arg_0._multi_graph.successors(arg_4):
                    arg_6 = arg_0._multi_graph.number_of_edges(arg_4, arg_5)
                    if arg_5 in arg_1:
                        arg_1[arg_5] -= arg_6
                    else:
                        arg_1[arg_5] = \
                            arg_0._multi_graph.in_degree(arg_5) - arg_6

                    if arg_1[arg_5] == 0:
                        arg_3.append(arg_5)
                        del arg_1[arg_5]

            yield arg_3
            arg_2 = arg_3
            arg_3 = []


(the_callable, label=None, schedule=DEFAULT_SCHEDULE, userdata=None, pk_override=None)

def Func(arg_0, arg_1=None, arg_2=arg_3, arg_4=None, arg_5=None):
    """Factory function to create a properly initialized task."""
    arg_6 = Task()
    if isinstance(arg_0, str):
        if arg_5 is not None:
            arg_7 = arg_0.split('.')
            arg_8 = dict(
                func_type='instancemethod',
                module_name='.'.join(arg_7[:-2]),
                class_name=arg_7[-2],
                class_path='.'.join(arg_7[:-1]),
                model_pk=arg_5,
                func_name=arg_7[-1],
                func_path=arg_0,
            )
            arg_6.funcinfo = arg_8
        else:
            arg_6.funcinfo = get_func_info(func_from_string(arg_0))
    else:
        arg_6.funcinfo = get_func_info(arg_0)

    if arg_1 is None:
        arg_6.label = arg_6.funcinfo['func_path']
    else:
        arg_6.label = arg_1

    arg_6.schedule = arg_2
    if not croniter.is_valid(arg_6.schedule):
        raise ValueError(f"Cron schedule {task.schedule} is not valid")

    if arg_4 is None:
        arg_6.userdata = dict()
    else:
        if isinstance(arg_4, dict):
            arg_6.userdata = arg_4
        else:
            raise ValueError("Userdata must be a dictionary of JSON-serializable data")

    return arg_6

Factory function to create a properly initialized task .


def Func ( arg_0 , arg_1 , arg_2 ) : arg_3 = "py.RecordSensor" arg_4 = json . dumps ( { "verbosity" : _VERBOSITY } ) arg_0 . addRegion ( arg_1 , arg_3 , arg_4 ) arg_5 = arg_0 . regions [ arg_1 ] . getSelf ( ) arg_5 . encoder = createEncoder ( ) arg_0 . regions [ arg_1 ] . setParameter ( "predictedField" , "consumption" ) arg_5 . dataSource = arg_2 return arg_5

def Func(arg_0, arg_1, arg_2):
  """
  Creates a RecordSensor region that allows us to specify a file record
  stream as the input source.
  """

  # Specific type of region. Possible options can be found in /nupic/regions/
  arg_3 = "py.RecordSensor"

  # Creates a json from specified dictionary.
  arg_4 = json.dumps({"verbosity": _VERBOSITY})
  arg_0.addRegion(arg_1, arg_3, arg_4)

  # getSelf returns the actual region, instead of a region wrapper
  arg_5 = arg_0.regions[arg_1].getSelf()

  # Specify how RecordSensor encodes input values
  arg_5.encoder = createEncoder()

  # Specify which sub-encoder should be used for "actValueOut"
  arg_0.regions[arg_1].setParameter("predictedField", "consumption")

  # Specify the dataSource as a file record stream instance
  arg_5.dataSource = arg_2
  return arg_5

Creates a RecordSensor region that allows us to specify a file record stream as the input source .


def Func ( arg_0 ) : arg_1 = record_get_field_instances ( arg_0 . record , '037' ) for arg_2 in arg_1 : arg_3 = field_get_subfields ( arg_2 ) for arg_4 in arg_3 . get ( "a" , [ ] ) : if "arXiv" not in arg_4 : record_delete_field ( arg_0 . record , tag = "037" , field_position_global = arg_2 [ 4 ] ) arg_5 = [ ( code , arg_4 [ 0 ] ) for code , arg_4 in arg_3 . items ( ) ] record_add_field ( arg_0 . record , "088" , subfields = arg_5 ) break

def Func(arg_0):
        """Update reportnumbers."""
        arg_1 = record_get_field_instances(arg_0.record, '037')
        for arg_2 in arg_1:
            arg_3 = field_get_subfields(arg_2)
            for arg_4 in arg_3.get("a", []):
                if "arXiv" not in arg_4:
                    record_delete_field(arg_0.record,
                                        tag="037",
                                        field_position_global=arg_2[4])
                    arg_5 = [(code, arg_4[0]) for code, arg_4 in arg_3.items()]
                    record_add_field(arg_0.record, "088", subfields=arg_5)
                    break


def Func ( arg_0 , arg_1 , arg_2 , arg_3 = { } ) : arg_4 = "__{}" . format ( arg_1 ) setattr ( arg_0 , arg_4 , None ) def getter ( arg_5 ) : arg_6 = getattr ( arg_0 , arg_4 ) if arg_6 is None : arg_6 = arg_2 ( ** arg_3 ) setattr ( arg_0 , arg_4 , arg_6 ) return arg_6 setattr ( type ( arg_0 ) , arg_1 , property ( getter ) )

def Func(arg_0, arg_1, arg_2, arg_3 = {}):
    """Creates a property with the given name, but the cls will created only with the first call

    Args:
        carrier: an instance of the class where want to reach the cls instance
        name (str): the variable name of the cls instance
        cls (type): the singleton object type
        cls_args (dict): optional dict for createing cls

    """
    arg_4 = "__{}".format(arg_1)
    setattr(arg_0, arg_4, None)

    def getter(arg_5):
        arg_6 = getattr(arg_0, arg_4)

        if arg_6 is None:
            arg_6 = arg_2(**arg_3)
            setattr(arg_0, arg_4, arg_6)

        return arg_6

    setattr(type(arg_0), arg_1, property(getter))

Creates a property with the given name but the cls will created only with the first call


def Func ( arg_0 , arg_1 = False ) : arg_2 = '' while len ( arg_0 ) > 0 : arg_3 = arg_0 [ 0 ] if arg_3 == '\\' : arg_4 = arg_0 [ 1 ] if arg_4 in ( 'u' , 'U' ) : arg_2 += six . unichr ( int ( arg_0 [ 2 : 6 ] , base = 16 ) ) arg_0 = arg_0 [ 6 : ] continue else : if arg_4 == 'b' : arg_2 += '\b' elif arg_4 == 'f' : arg_2 += '\f' elif arg_4 == 'n' : arg_2 += '\n' elif arg_4 == 'r' : arg_2 += '\r' elif arg_4 == 't' : arg_2 += '\t' else : if arg_1 and ( arg_4 == '#' ) : arg_2 += '\\' arg_2 += arg_4 arg_0 = arg_0 [ 2 : ] continue else : arg_2 += arg_3 arg_0 = arg_0 [ 1 : ] return arg_2

def Func(arg_0, arg_1=False):
    """
    Iterative parser for string escapes.
    """
    arg_2 = ''
    while len(arg_0) > 0:
        arg_3 = arg_0[0]
        if arg_3 == '\\':
            # Backslash escape
            arg_4 = arg_0[1]

            if arg_4 in ('u', 'U'):
                # Unicode escape
                arg_2 += six.unichr(int(arg_0[2:6], base=16))
                arg_0 = arg_0[6:]
                continue
            else:
                if arg_4 == 'b':
                    arg_2 += '\b'
                elif arg_4 == 'f':
                    arg_2 += '\f'
                elif arg_4 == 'n':
                    arg_2 += '\n'
                elif arg_4 == 'r':
                    arg_2 += '\r'
                elif arg_4 == 't':
                    arg_2 += '\t'
                else:
                    if arg_1 and (arg_4 == '#'):
                        # \# is passed through with backslash.
                        arg_2 += '\\'
                    # Pass through
                    arg_2 += arg_4
                arg_0 = arg_0[2:]
                continue
        else:
            arg_2 += arg_3
            arg_0 = arg_0[1:]
    return arg_2


(
            self, keywords=None, max_domain_recommendations=None, custom_headers=None, raw=False, **operation_config)

def
Func
(
arg_0
,
arg_1
=
,
arg_2
=
,
arg_3
=
,
arg_4
=
False
,
**
arg_5
)
:
arg_6
=
models
.
DomainRecommendationSearchParameters
(
arg_1
=
arg_1
,
arg_2
=
arg_2
)
def
internal_paging
(
arg_7
=
,
arg_4
=
False
)
:
if
not
arg_7
:
arg_8
=
arg_0
.
Func
.
metadata
[
'url'
]
arg_9
=
{
'subscriptionId'
:
arg_0
.
_serialize
.
url
(
"self.config.subscription_id"
,
arg_0
.
config
.
subscription_id
,
'str'
)
}
arg_8
=
arg_0
.
_client
.
format_url
(
arg_8
,
**
arg_9
)
arg_10
=
{
}
arg_10
[
'api-version'
]
=
arg_0
.
_serialize
.
query
(
"self.api_version"
,
arg_0
.
api_version
,
'str'
)
else
:
arg_8
=
arg_7
arg_10
=
{
}
arg_11
=
{
}
arg_11
[
'Accept'
]
=
'application/json'
arg_11
[
'Content-Type'
]
=
'application/json; charset=utf-8'
if
arg_0
.
config
.
generate_client_request_id
:
arg_11
[
'x-ms-client-request-id'
]
=
str
(
uuid
.
uuid1
(
)
)
if
arg_3
:
arg_11
.
update
(
arg_3
)
if
arg_0
.
config
.
accept_language
is
not
:
arg_11
[
'accept-language'
]
=
arg_0
.
_serialize
.
header
(
"self.config.accept_language"
,
arg_0
.
config
.
accept_language
,
'str'
)
arg_12
=
arg_0
.
_serialize
.
body
(
arg_6
,
'DomainRecommendationSearchParameters'
)
arg_13
=
arg_0
.
_client
.
post
(
arg_8
,
arg_10
,
arg_11
,
arg_12
)
arg_14
=
arg_0
.
_client
.
send
(
arg_13
,
stream
=
False
,
**
arg_5
)
if
arg_14
.
status_code
not
in
[
200
]
:
raise
models
.
DefaultErrorResponseException
(
arg_0
.
_deserialize
,
arg_14
)
return
arg_14
arg_15
=
models
.
NameIdentifierPaged
(
internal_paging
,
arg_0
.
_deserialize
.
dependencies
)
if
arg_4
:
arg_16
=
{
}
arg_17
=
models
.
NameIdentifierPaged
(
internal_paging
,
arg_0
.
_deserialize
.
dependencies
,
arg_16
)
return
arg_17
return
arg_15

def Func(
            arg_0, arg_1=None, arg_2=None, arg_3=None, arg_4=False, **arg_5):
        """Get domain name recommendations based on keywords.

        Get domain name recommendations based on keywords.

        :param keywords: Keywords to be used for generating domain
         recommendations.
        :type keywords: str
        :param max_domain_recommendations: Maximum number of recommendations.
        :type max_domain_recommendations: int
        :param dict custom_headers: headers that will be added to the request
        :param bool raw: returns the direct response alongside the
         deserialized response
        :param operation_config: :ref:`Operation configuration
         overrides<msrest:optionsforoperations>`.
        :return: An iterator like instance of NameIdentifier
        :rtype:
         ~azure.mgmt.web.models.NameIdentifierPaged[~azure.mgmt.web.models.NameIdentifier]
        :raises:
         :class:`DefaultErrorResponseException<azure.mgmt.web.models.DefaultErrorResponseException>`
        """
        arg_6 = models.DomainRecommendationSearchParameters(arg_1=arg_1, arg_2=arg_2)

        def internal_paging(arg_7=None, arg_4=False):

            if not arg_7:
                # Construct URL
                arg_8 = arg_0.Func.metadata['url']
                arg_9 = {
                    'subscriptionId': arg_0._serialize.url("self.config.subscription_id", arg_0.config.subscription_id, 'str')
                }
                arg_8 = arg_0._client.format_url(arg_8, **arg_9)

                # Construct parameters
                arg_10 = {}
                arg_10['api-version'] = arg_0._serialize.query("self.api_version", arg_0.api_version, 'str')

            else:
                arg_8 = arg_7
                arg_10 = {}

            # Construct headers
            arg_11 = {}
            arg_11['Accept'] = 'application/json'
            arg_11['Content-Type'] = 'application/json; charset=utf-8'
            if arg_0.config.generate_client_request_id:
                arg_11['x-ms-client-request-id'] = str(uuid.uuid1())
            if arg_3:
                arg_11.update(arg_3)
            if arg_0.config.accept_language is not None:
                arg_11['accept-language'] = arg_0._serialize.header("self.config.accept_language", arg_0.config.accept_language, 'str')

            # Construct body
            arg_12 = arg_0._serialize.body(arg_6, 'DomainRecommendationSearchParameters')

            # Construct and send request
            arg_13 = arg_0._client.post(arg_8, arg_10, arg_11, arg_12)
            arg_14 = arg_0._client.send(arg_13, stream=False, **arg_5)

            if arg_14.status_code not in [200]:
                raise models.DefaultErrorResponseException(arg_0._deserialize, arg_14)

            return arg_14

        # Deserialize response
        arg_15 = models.NameIdentifierPaged(internal_paging, arg_0._deserialize.dependencies)

        if arg_4:
            arg_16 = {}
            arg_17 = models.NameIdentifierPaged(internal_paging, arg_0._deserialize.dependencies, arg_16)
            return arg_17

        return arg_15

Get domain name recommendations based on keywords .


def Func(arg_0, arg_1):
    """ Return the bit offset of the first bit to be set in the encoder output.
    For periodic encoders, this can be a negative number when the encoded output
    wraps around. """

    if arg_1 == SENTINEL_VALUE_FOR_MISSING_DATA:
      return [None]

    else:
      if arg_1 < arg_0.minval:
        # Don't clip periodic inputs. Out-of-range input is always an error
        if arg_0.clipInput and not arg_0.periodic:
          if arg_0.verbosity > 0:
            print "Clipped input %s=%.2f to minval %.2f" % (arg_0.name, arg_1,
                                                            arg_0.minval)
          arg_1 = arg_0.minval
        else:
          raise Exception('input (%s) less than range (%s - %s)' %
                          (str(arg_1), str(arg_0.minval), str(arg_0.maxval)))

      if arg_0.periodic:
        # Don't clip periodic inputs. Out-of-range input is always an error
        if arg_1 >= arg_0.maxval:
          raise Exception('input (%s) greater than periodic range (%s - %s)' %
                          (str(arg_1), str(arg_0.minval), str(arg_0.maxval)))
      else:
        if arg_1 > arg_0.maxval:
          if arg_0.clipInput:
            if arg_0.verbosity > 0:
              print "Clipped input %s=%.2f to maxval %.2f" % (arg_0.name, arg_1,
                                                              arg_0.maxval)
            arg_1 = arg_0.maxval
          else:
            raise Exception('input (%s) greater than range (%s - %s)' %
                            (str(arg_1), str(arg_0.minval), str(arg_0.maxval)))

      if arg_0.periodic:
        arg_2 = int((arg_1 - arg_0.minval) * arg_0.nInternal / arg_0.range) \
                      + arg_0.padding
      else:
        arg_2 = int(((arg_1 - arg_0.minval) + arg_0.resolution/2) \
                          / arg_0.resolution ) + arg_0.padding

      # We use the first bit to be set in the encoded output as the bucket index
      arg_3 = arg_2 - arg_0.halfwidth
      return [arg_3]

Return the bit offset of the first bit to be set in the encoder output . For periodic encoders this can be a negative number when the encoded output wraps around .


def Func(arg_0):
        """Parse the user data header portion of the replay."""
        arg_1 = OrderedDict()
        arg_2 = arg_0.archive.header['user_data_header']['content']
        if re.search(r'StarCraft II replay', arg_2):
            arg_2 = StringIO.StringIO(arg_2)
            arg_2.seek(30) # Just skip the beginning.
            arg_1.update(read_table(arg_2, ['release_flag',
                                                        'major_version',
                                                        'minor_version',
                                                        'maintenance_version',
                                                        'build_number',
                                                        'unknown',
                                                        'unknown',
                                                        'duration']))

            # Some post processing is required.
            arg_1['version'] = '%s.%s.%s.%s' % (arg_1['major_version'],
                                                 arg_1['minor_version'],
                                                 arg_1['maintenance_version'],
                                                 arg_1['build_number'])
            if not arg_1['release_flag']:
                arg_1['version'] += ' (dev)'

            # Duration is actually stored as 1/16th of a seconds. Go figure.
            arg_1['duration'] /= 16
        else:
            raise ValueError("The given file is not a StarCraft II replay.")
        return arg_1

Parse the user data header portion of the replay .


def Func ( arg_0 ) : @ functools . wraps ( arg_0 ) def _new_getter ( arg_1 , * arg_2 , ** arg_3 ) : arg_4 = [ ] while hasattr ( arg_1 , 'inner_results' ) : arg_4 . append ( arg_1 ) arg_1 = arg_1 . inner_results return arg_0 ( arg_1 , * arg_2 , ** arg_3 ) return _new_getter

def Func(arg_0):
  """Wraps a getter so it applies to the inner-most results in `kernel_results`.

  The wrapped getter unwraps `kernel_results` and returns the return value of
  `getter` called with the first results without an `inner_results` attribute.

  Args:
    getter: A callable that takes Kernel results and returns some value.

  Returns:
    new_getter: A wrapped `getter`.
  """

  @functools.wraps(arg_0)
  def _new_getter(arg_1, *arg_2, **arg_3):
    """Wrapped getter."""
    arg_4 = []
    while hasattr(arg_1, 'inner_results'):
      arg_4.append(arg_1)
      arg_1 = arg_1.inner_results

    return arg_0(arg_1, *arg_2, **arg_3)

  return _new_getter

Wraps a getter so it applies to the inner - most results in kernel_results .


def Func ( arg_0 ) : arg_1 = arg_0 . project if isinstance ( arg_0 , Asset ) : arg_2 = True else : arg_2 = False arg_3 = arg_1 . department_set . filter ( assetflag = arg_2 ) for arg_4 in arg_3 : arg_5 = Task ( project = arg_1 , department = arg_4 , arg_0 = arg_0 ) arg_5 . full_clean ( ) arg_5 . save ( )

def Func(arg_0):
    """Create all tasks for the element

    :param element: The shot or asset that needs tasks
    :type element: :class:`muke.models.Shot` | :class:`muke.models.Asset`
    :returns: None
    :rtype: None
    :raises: None
    """
    arg_1 = arg_0.project
    if isinstance(arg_0, Asset):
        arg_2=True
    else:
        arg_2=False
    arg_3 = arg_1.department_set.filter(assetflag=arg_2)
    for arg_4 in arg_3:
        arg_5 = Task(project=arg_1, department=arg_4, arg_0=arg_0)
        arg_5.full_clean()
        arg_5.save()


(self, table_name, sample, unique_fields=None)

def Func ( arg_0 , arg_1 , arg_2 , arg_3 = None ) : try : arg_4 = find_unique ( arg_0 . table ( arg_1 ) , arg_2 = arg_2 , arg_3 = arg_3 ) except : return False else : return arg_4 is not None

def Func(arg_0, arg_1, arg_2, arg_3=None):
        """Return True if an item with the value of `unique_fields`
        from `data` is unique in the table with `table_name`.
        False if no sample is found or more than one is found.

        See function `find_unique` for more details.

        Parameters
        ----------
        table_name: str

        sample: dict
            Sample data for query

        unique_fields: str or list of str

        Returns
        -------
        Func: bool
        """
        try:
            arg_4 = find_unique(arg_0.table(arg_1),
                              arg_2=arg_2,
                              arg_3=arg_3)
        except:
            return False
        else:
            return arg_4 is not None

Return True if an item with the value of `unique_fields`
        from `data` is unique in the table with `table_name`.
        False if no sample is found or more than one is found.

        See function `find_unique` for more details.

        Parameters
        ----------
        table_name: str

        sample: dict
            Sample data for query

        unique_fields: str or list of str

        Returns
        -------
        is_unique: bool

Return True if an item with the value of unique_fields from data is unique in the table with table_name . False if no sample is found or more than one is found .


def Func ( arg_0 , arg_1 , arg_2 = True ) : util . valid_audio ( arg_0 , mono = False ) arg_3 = [ ] if arg_2 : arg_4 = core . to_mono ( arg_0 ) arg_5 = np . nonzero ( core . zero_crossings ( arg_4 ) ) [ - 1 ] arg_5 = np . append ( arg_5 , [ len ( arg_4 ) ] ) arg_6 = [ slice ( None ) ] * arg_0 . ndim for arg_7 in arg_1 : if arg_2 : arg_7 = arg_5 [ util . match_events ( arg_7 , arg_5 ) ] arg_6 [ - 1 ] = slice ( arg_7 [ 0 ] , arg_7 [ 1 ] ) arg_3 . append ( arg_0 [ tuple ( arg_6 ) ] ) return np . concatenate ( arg_3 , axis = - 1 )

def Func(arg_0, arg_1, arg_2=True):
    '''Remix an audio signal by re-ordering time intervals.

    Parameters
    ----------
    y : np.ndarray [shape=(t,) or (2, t)]
        Audio time series

    intervals : iterable of tuples (start, end)
        An iterable (list-like or generator) where the `i`th item
        `intervals[i]` indicates the start and end (in samples)
        of a slice of `y`.

    align_zeros : boolean
        If `True`, interval boundaries are mapped to the closest
        zero-crossing in `y`.  If `y` is stereo, zero-crossings
        are computed after converting to mono.

    Returns
    -------
    y_Func : np.ndarray [shape=(d,) or (2, d)]
        `y` Funced in the order specified by `intervals`

    Examples
    --------
    Load in the example track and reverse the beats

    >>> y, sr = librosa.load(librosa.util.example_audio_file())

    Compute beats

    >>> _, beat_frames = librosa.beat.beat_track(y=y, sr=sr,
    ...                                          hop_length=512)

    Convert from frames to sample indices

    >>> beat_samples = librosa.frames_to_samples(beat_frames)

    Generate intervals from consecutive events

    >>> intervals = librosa.util.frame(beat_samples, frame_length=2,
    ...                                hop_length=1).T

    Reverse the beat intervals

    >>> y_out = librosa.effects.Func(y, intervals[::-1])
    '''

    # Validate the audio buffer
    util.valid_audio(arg_0, mono=False)

    arg_3 = []

    if arg_2:
        arg_4 = core.to_mono(arg_0)
        arg_5 = np.nonzero(core.zero_crossings(arg_4))[-1]
        # Force end-of-signal onto zeros
        arg_5 = np.append(arg_5, [len(arg_4)])

    arg_6 = [slice(None)] * arg_0.ndim

    for arg_7 in arg_1:

        if arg_2:
            arg_7 = arg_5[util.match_events(arg_7, arg_5)]

        arg_6[-1] = slice(arg_7[0], arg_7[1])

        arg_3.append(arg_0[tuple(arg_6)])

    return np.concatenate(arg_3, axis=-1)

Remix an audio signal by re-ordering time intervals.

    Parameters
    ----------
    y : np.ndarray [shape=(t,) or (2, t)]
        Audio time series

    intervals : iterable of tuples (start, end)
        An iterable (list-like or generator) where the `i`th item
        `intervals[i]` indicates the start and end (in samples)
        of a slice of `y`.

    align_zeros : boolean
        If `True`, interval boundaries are mapped to the closest
        zero-crossing in `y`.  If `y` is stereo, zero-crossings
        are computed after converting to mono.

    Returns
    -------
    y_remix : np.ndarray [shape=(d,) or (2, d)]
        `y` remixed in the order specified by `intervals`

    Examples
    --------
    Load in the example track and reverse the beats

    >>> y, sr = librosa.load(librosa.util.example_audio_file())

    Compute beats

    >>> _, beat_frames = librosa.beat.beat_track(y=y, sr=sr,
    ...                                          hop_length=512)

    Convert from frames to sample indices

    >>> beat_samples = librosa.frames_to_samples(beat_frames)

    Generate intervals from consecutive events

    >>> intervals = librosa.util.frame(beat_samples, frame_length=2,
    ...                                hop_length=1).T

    Reverse the beat intervals

    >>> y_out = librosa.effects.remix(y, intervals[::-1])

Remix an audio signal by re - ordering time intervals .


def Func ( arg_0 , arg_1 ) : arg_2 = arg_0 . get_conn ( ) . Func ( ClusterIdentifier = arg_1 ) if 'Snapshots' not in arg_2 : return None arg_3 = arg_2 [ 'Snapshots' ] arg_3 = filter ( lambda x : x [ 'Status' ] , arg_3 ) arg_3 . sort ( key = lambda x : x [ 'SnapshotCreateTime' ] , reverse = True ) return arg_3

def Func(arg_0, arg_1):
        """
        Gets a list of snapshots for a cluster

        :param cluster_identifier: unique identifier of a cluster
        :type cluster_identifier: str
        """
        arg_2 = arg_0.get_conn().Func(
            ClusterIdentifier=arg_1
        )
        if 'Snapshots' not in arg_2:
            return None
        arg_3 = arg_2['Snapshots']
        arg_3 = filter(lambda x: x['Status'], arg_3)
        arg_3.sort(key=lambda x: x['SnapshotCreateTime'], reverse=True)
        return arg_3


return mapping_util.unmasked_sparse_to_sparse_from_mask_and_pixel_centres(
            mask=self.regular_grid.mask,
            unmasked_sparse_grid_pixel_centres=self.unmasked_sparse_grid_pixel_centres,
            total_sparse_pixels=self.total_sparse_pixels).astype(
            'int')

def Func ( arg_0 ) : return mapping_util . Func_from_mask_and_pixel_centres ( mask = arg_0 . regular_grid . mask , unmasked_sparse_grid_pixel_centres = arg_0 . unmasked_sparse_grid_pixel_centres , total_sparse_pixels = arg_0 . total_sparse_pixels ) . astype ( 'int' )

def Func(arg_0):
        """The 1D index mappings between the unmasked sparse-grid and masked sparse grid."""

        return mapping_util.Func_from_mask_and_pixel_centres(
            mask=arg_0.regular_grid.mask,
            unmasked_sparse_grid_pixel_centres=arg_0.unmasked_sparse_grid_pixel_centres,
            total_sparse_pixels=arg_0.total_sparse_pixels).astype(
            'int')

The 1D index mappings between the unmasked sparse - grid and masked sparse grid .


def Func ( arg_0 ) : def decorator ( arg_1 ) : @ wraps ( arg_1 ) def wrapper ( * arg_2 , ** arg_3 ) : warnings . simplefilter ( 'ignore' , arg_0 ) return arg_1 ( * arg_2 , ** arg_3 ) return wrapper return decorator

def Func(arg_0):
    """
    Ignore any emitted warnings from a function.

    :param warning: The category of warning to ignore.
    """
    def decorator(arg_1):
        """
        Return a decorated function whose emitted warnings are ignored.
        """
        @wraps(arg_1)
        def wrapper(*arg_2, **arg_3):
            """
            Wrap the function.
            """
            warnings.simplefilter('ignore', arg_0)
            return arg_1(*arg_2, **arg_3)
        return wrapper
    return decorator

Ignore any emitted warnings from a function .


def Func ( arg_0 , arg_1 ) : if all ( [ isinstance ( getattr ( arg_2 , arg_1 ) , TimeVariable ) for arg_2 in arg_0 . _series ] ) : return 'time' return None

def Func(arg_0, arg_1):
        "will get the axis mode for the current series"
        if all([isinstance(getattr(arg_2, arg_1), TimeVariable) for arg_2 in arg_0._series]):
            return 'time'
        return None


def Func(arg_0, arg_1, arg_2=True):
    """Custom grouping from a given serialized string

    This class is created for compatibility with ``Func(cls, java_serialized)`` method
    of StreamParse API, although its functionality is not yet implemented (Java-serialized).
    Currently only custom grouping implemented in Python is supported, and ``custom()`` method
    should be used to indicate its classpath, rather than directly to use this method.

    In the future, users can directly specify Java-serialized object with ``is_java=True`` in order
    to use a custom grouping implemented in Java for python topology.

    :param serialized: serialized classpath to custom grouping class to use (if python)
    :param is_java: indicate whether this is Java serialized, or python serialized
    """
    if not isinstance(arg_1, bytes):
      raise TypeError("Argument to Func() must be "
                      "a serialized Python class as bytes, given: %s" % str(arg_1))
    if not arg_2:
      return arg_0.CUSTOM(gtype=topology_pb2.Grouping.Value("CUSTOM"),
                        python_serialized=arg_1)
    else:
      raise NotImplementedError("Custom grouping implemented in Java for Python topology"
                                "is not yet supported.")

Custom grouping from a given serialized string

    This class is created for compatibility with ``custom_serialized(cls, java_serialized)`` method
    of StreamParse API, although its functionality is not yet implemented (Java-serialized).
    Currently only custom grouping implemented in Python is supported, and ``custom()`` method
    should be used to indicate its classpath, rather than directly to use this method.

    In the future, users can directly specify Java-serialized object with ``is_java=True`` in order
    to use a custom grouping implemented in Java for python topology.

    :param serialized: serialized classpath to custom grouping class to use (if python)
    :param is_java: indicate whether this is Java serialized, or python serialized


def
Func
(
arg_0
,
arg_1
,
arg_2
=
)
:
if
isinstance
(
arg_1
,
io
.
TextIOWrapper
)
:
arg_0
.
input
=
arg_1
elif
isinstance
(
arg_1
,
'string'
.
__class__
)
:
arg_0
.
name
=
arg_1
arg_0
.
input
=
Func
(
arg_1
,
'r'
)
else
:
raise
IOError
(
"Invalid input type (%s) for %s"
%
(
arg_1
.
__class__
.
__name__
,
arg_1
)
)
return

def Func(arg_0, arg_1, arg_2=None):
        """Use this to set what file to read from. """
        if isinstance(arg_1, io.TextIOWrapper):
            arg_0.input = arg_1
        elif isinstance(arg_1, 'string'.__class__):  # FIXME
            arg_0.name  = arg_1
            arg_0.input = Func(arg_1, 'r')
        else:
            raise IOError("Invalid input type (%s) for %s" %
                          (arg_1.__class__.__name__, arg_1))
        return

Use this to set what file to read from .


def Func(arg_0=None):
    """Read settings from a config file in the source_dir root."""

    arg_1 = logging.getLogger(__name__)
    arg_1.info("Reading settings ...")
    arg_2 = _DEFAULT_CONFIG.copy()

    if arg_0:
        arg_1.debug("Settings file: %s", arg_0)
        arg_3 = os.path.dirname(arg_0)
        arg_4 = {}

        with open(arg_0) as f:
            arg_5 = compile(f.read(), arg_0, 'exec')
            exec(arg_5, arg_4)

        arg_2.update((arg_6, arg_7) for arg_6, arg_7 in arg_4.items()
                        if arg_6 not in ['__builtins__'])

        # Make the paths relative to the settings file
        arg_8 = ['source', 'destination', 'watermark']

        if os.path.isdir(join(arg_3, arg_2['theme'])) and \
                os.path.isdir(join(arg_3, arg_2['theme'],
                                   'templates')):
            arg_8.append('theme')

        for arg_9 in arg_8:
            arg_10 = arg_2[arg_9]
            if arg_10 and not isabs(arg_10):
                arg_2[arg_9] = abspath(normpath(join(arg_3, arg_10)))
                arg_1.debug("Rewrite %s : %s -> %s", arg_9, arg_10, arg_2[arg_9])

    for arg_11 in ('img_size', 'thumb_size', 'video_size'):
        arg_12, arg_13 = arg_2[arg_11]
        if arg_13 > arg_12:
            arg_2[arg_11] = (arg_13, arg_12)
            arg_1.warning("The %s setting should be specified with the "
                           "largest value first.", arg_11)

    if not arg_2['img_processor']:
        arg_1.info('No Processor, images will not be resized')

    arg_1.debug('Settings:\n%s', pformat(arg_2, width=120))
    return arg_2

Read settings from a config file in the source_dir root .


def
Func
(
arg_0
)
:
while
1
:
_log
(
'info'
,
' * Restarting with %s'
%
arg_0
.
name
)
arg_1
=
[
sys
.
executable
]
+
sys
.
argv
arg_2
=
os
.
environ
.
copy
(
)
arg_2
[
'WERKZEUG_RUN_MAIN'
]
=
'true'
if
os
.
name
==
'nt'
and
PY2
:
for
arg_3
,
arg_4
in
iteritems
(
arg_2
)
:
if
isinstance
(
arg_4
,
text_type
)
:
arg_2
[
arg_3
]
=
arg_4
.
encode
(
'iso-8859-1'
)
arg_5
=
subprocess
.
call
(
arg_1
,
env
=
arg_2
)
if
arg_5
!=
3
:
return
arg_5

def Func(arg_0):
        """Spawn a new Python interpreter with the same arguments as this one,
        but running the reloader thread.
        """
        while 1:
            _log('info', ' * Restarting with %s' % arg_0.name)
            arg_1 = [sys.executable] + sys.argv
            arg_2 = os.environ.copy()
            arg_2['WERKZEUG_RUN_MAIN'] = 'true'

            # a weird bug on windows. sometimes unicode strings end up in the
            # environment and subprocess.call does not like this, encode them
            # to latin1 and continue.
            if os.name == 'nt' and PY2:
                for arg_3, arg_4 in iteritems(arg_2):
                    if isinstance(arg_4, text_type):
                        arg_2[arg_3] = arg_4.encode('iso-8859-1')

            arg_5 = subprocess.call(arg_1, env=arg_2)
            if arg_5 != 3:
                return arg_5

Spawn a new Python interpreter with the same arguments as this one but running the reloader thread .


def Func ( arg_0 , arg_1 = arg_2 ) : if hasattr ( arg_0 , 'email' ) : arg_3 = arg_0 . email else : arg_3 = arg_0 try : return escape ( get_Func ( arg_3 = arg_3 , arg_1 = arg_1 ) ) except : return ''

def Func(arg_0, arg_1=arg_2):
    """ Builds a gravatar url from an user or email """
    if hasattr(arg_0, 'email'):
        arg_3 = arg_0.email
    else:
        arg_3 = arg_0

    try:
        return escape(get_Func(arg_3=arg_3, arg_1=arg_1))
    except:
        return ''


return {
        exc.name
        for _, exc, _ in graph.warnings
        if isinstance(exc, (MissingNamespaceNameWarning, MissingNamespaceRegexWarning)) and exc.namespace == namespace
    }

def Func ( arg_0 : arg_1 , arg_2 : arg_3 ) -> Set [ arg_3 ] : return { arg_5 . name for arg_4 , arg_5 , arg_4 in arg_0 . warnings if isinstance ( arg_5 , ( MissingNamespaceNameWarning , MissingNamespaceRegexWarning ) ) and arg_5 . namespace == arg_2 }

def Func(arg_0: arg_1, arg_2: arg_3) -> Set[arg_3]:
    """Return the set of all incorrect names from the given namespace in the graph.

    :return: The set of all incorrect names from the given namespace in the graph
    """
    return {
        arg_5.name
        for arg_4, arg_5, arg_4 in arg_0.warnings
        if isinstance(arg_5, (MissingNamespaceNameWarning, MissingNamespaceRegexWarning)) and arg_5.namespace == arg_2
    }

Return the set of all incorrect names from the given namespace in the graph .


def Func(arg_0, arg_1, arg_2):
        """
        Updates the SIS ID for the account identified by the passed account ID.

        https://canvas.instructure.com/doc/api/accounts.html#method.accounts.update
        """
        if arg_1 == arg_0._canvas_account_id:
            raise Exception("SIS ID cannot be updated for the root account")

        arg_3 = ACCOUNTS_API.format(arg_1)
        arg_4 = {"account": {"sis_account_id": arg_2}}

        return CanvasAccount(data=arg_0._put_resource(arg_3, arg_4))

Updates the SIS ID for the account identified by the passed account ID .


(self, dataset_id, table_resource, project_id=None)

def Func(arg_0, arg_1, arg_2, arg_3=None):
        """
        creates a new, empty table in the dataset;
        If the table already exists, update the existing table.
        Since BigQuery does not natively allow table upserts, this is not an
        atomic operation.

        :param dataset_id: the dataset to upsert the table into.
        :type dataset_id: str
        :param table_resource: a table resource. see
            https://cloud.google.com/bigquery/docs/reference/v2/tables#resource
        :type table_resource: dict
        :param project_id: the project to upsert the table into.  If None,
            project will be self.project_id.
        :return:
        """
        # check to see if the table exists
        arg_4 = arg_2['tableReference']['tableId']
        arg_3 = arg_3 if arg_3 is not None else arg_0.project_id
        arg_5 = arg_0.service.tables().list(
            projectId=arg_3, datasetId=arg_1).execute(num_retries=arg_0.num_retries)
        while True:
            for arg_6 in arg_5.get('tables', []):
                if arg_6['tableReference']['tableId'] == arg_4:
                    # found the table, do update
                    arg_0.log.info('Table %s:%s.%s exists, updating.',
                                  arg_3, arg_1, arg_4)
                    return arg_0.service.tables().update(
                        projectId=arg_3,
                        datasetId=arg_1,
                        tableId=arg_4,
                        body=arg_2).execute(num_retries=arg_0.num_retries)
            # If there is a next page, we need to check the next page.
            if 'nextPageToken' in arg_5:
                arg_5 = arg_0.service.tables()\
                    .list(projectId=arg_3,
                          datasetId=arg_1,
                          pageToken=arg_5['nextPageToken'])\
                    .execute(num_retries=arg_0.num_retries)
            # If there is no next page, then the table doesn't exist.
            else:
                # do insert
                arg_0.log.info('Table %s:%s.%s does not exist. creating.',
                              arg_3, arg_1, arg_4)
                return arg_0.service.tables().insert(
                    projectId=arg_3,
                    datasetId=arg_1,
                    body=arg_2).execute(num_retries=arg_0.num_retries)

creates a new empty table in the dataset ; If the table already exists update the existing table . Since BigQuery does not natively allow table upserts this is not an atomic operation .


(cls, key, name, mean=b"com.apple.iTunes")

def Func ( arg_0 , arg_1 , arg_2 , arg_3 = b"com.apple.iTunes" ) : arg_4 = b"----:" + arg_3 + b":" + arg_2 def getter ( arg_5 , arg_1 ) : return [ arg_6 . decode ( "utf-8" , "replace" ) for arg_6 in arg_5 [ arg_4 ] ] def setter ( arg_5 , arg_1 , arg_7 ) : arg_5 [ arg_4 ] = [ utf8 ( v ) for v in arg_7 ] def deleter ( arg_5 , arg_1 ) : del ( arg_5 [ arg_4 ] ) arg_0 . RegisterKey ( arg_1 , getter , setter , deleter )

def Func(arg_0, arg_1, arg_2, arg_3=b"com.apple.iTunes"):
        """Register a text key.

        If the key you need to register is a simple one-to-one mapping
        of MP4 freeform atom (----) and name to EasyMP4Tags key, then
        you can use this function::

            EasyMP4Tags.Func(
                "musicbrainz_artistid", b"MusicBrainz Artist Id")
        """
        arg_4 = b"----:" + arg_3 + b":" + arg_2

        def getter(arg_5, arg_1):
            return [arg_6.decode("utf-8", "replace") for arg_6 in arg_5[arg_4]]

        def setter(arg_5, arg_1, arg_7):
            arg_5[arg_4] = [utf8(v) for v in arg_7]

        def deleter(arg_5, arg_1):
            del(arg_5[arg_4])

        arg_0.RegisterKey(arg_1, getter, setter, deleter)

Register a text key.

        If the key you need to register is a simple one-to-one mapping
        of MP4 freeform atom (----) and name to EasyMP4Tags key, then
        you can use this function::

            EasyMP4Tags.RegisterFreeformKey(
                "musicbrainz_artistid", b"MusicBrainz Artist Id")


def Func ( arg_0 ) : arg_1 = current_app . config . get ( 'SECRET_KEY' ) arg_2 = URLSafeSerializer ( arg_1 ) return arg_2 . dumps ( arg_0 )

def Func(arg_0):
    """Encode something with SECRET_KEY."""
    arg_1 = current_app.config.get('SECRET_KEY')
    arg_2 = URLSafeSerializer(arg_1)
    return arg_2.dumps(arg_0)


def Func(arg_0):
    """Parse a type comment string into AST nodes."""
    try:
        arg_1 = ast3.parse(arg_0, '<type_comment>', 'eval')
    except SyntaxError:
        raise ValueError(f"invalid type comment: {type_comment!r}") from None

    assert isinstance(arg_1, ast3.Expression)
    return arg_1.body

Parse a type comment string into AST nodes .


return self._client.abort(self.msg_ids, targets=self._targets, block=True)

def
Func
(
arg_0
)
:
assert
not
arg_0
.
ready
(
)
,
"Can't Func, I am already done!"
return
arg_0
.
_client
.
Func
(
arg_0
.
msg_ids
,
targets
=
arg_0
.
_targets
,
block
=
True
)

def Func(arg_0):
        """Func my tasks."""
        assert not arg_0.ready(), "Can't Func, I am already done!"
        return arg_0._client.Func(arg_0.msg_ids, targets=arg_0._targets, block=True)


def Func(arg_0, arg_1):
    """
    walk parameter instances on this interface
    """
    for arg_2 in arg_0._interfaces:
        yield from Func(arg_2, arg_1)

    for arg_3 in arg_0._params:
        if arg_3 not in arg_1:
            arg_1.add(arg_3)
            yield arg_3


def Func(arg_0, arg_1, arg_2):
        """
        Returns a batched queryset of EnterpriseCustomerUser objects.
        """
        LOGGER.info('Fetching new batch of enterprise customer users from indexes: %s to %s', arg_1, arg_2)
        return User.objects.filter(pk__in=arg_0._get_enterprise_customer_user_ids())[arg_1:arg_2]

Returns a batched queryset of EnterpriseCustomerUser objects .


(self,
                  ax,
                  legend,
                  ladder=False,
                  default_width=1,
                  match_only=None,
                  colour=None,
                  colour_function=None,
                  cmap=None,
                  default=None,
                  width_field=None,
                  **kwargs
                  )

def Func(arg_0,
                  arg_1,
                  arg_2,
                  arg_3=False,
                  arg_4=1,
                  arg_5=None,
                  arg_6=None,
                  arg_7=None,
                  arg_8=None,
                  arg_9=None,
                  arg_10=None,
                  **arg_11
                  ):
        """
        Plotting, but only the Rectangles. You have to set up the figure.
        Returns a matplotlib axis object.

        Args:
            ax (axis): The matplotlib axis to plot into.
            legend (Legend): The Legend to use for colours, etc.
            ladder (bool): Whether to use widths or not. Default False.
            default_width (int): A width for the plot if not using widths.
                Default 1.
            match_only (list): A list of strings matching the attributes you
                want to compare when plotting.
            colour (str): Which data field to use for colours.
            cmap (cmap): Matplotlib colourmap. Default ``viridis``.
            default (float): The default (null) value.
            width_field (str): The field to use for the width of the patches.
            **kwargs are passed through to matplotlib's ``patches.Rectangle``.

        Returns:
            axis: The matplotlib.pyplot axis.
        """
        arg_12 = None
        arg_13 = []
        for arg_14 in arg_0.__list:
            arg_15 = (0, arg_14.top.z)
            arg_16 = arg_2.get_decor(arg_14.primary, arg_5=arg_5)
            arg_17 = arg_14.base.z - arg_14.top.z

            if arg_3:
                if arg_10 is not None:
                    arg_18 = arg_14.data.get(arg_10, 1)
                    arg_18 = arg_4 * arg_18/arg_0.max_field(arg_10)
                    arg_12 = 'gray'
                elif arg_2 is not None:
                    arg_18 = arg_16.width or arg_4
                    try:
                        arg_18 = arg_4 * arg_18/arg_2.max_width
                    except:
                        arg_18 = arg_4
            else:
                arg_18 = arg_4

            # Allow override of lw
            arg_19 = arg_11.copy()
            arg_20 = arg_19.pop('lw', 0)
            arg_21 = arg_19.pop('ec', 'k')
            arg_22 = arg_19.pop('fc', None) or arg_12 or arg_16.colour

            if arg_6 is None:
                arg_23 = mpl.patches.Rectangle(arg_15,
                                             arg_18,
                                             arg_17,
                                             arg_22=arg_22,
                                             arg_20=arg_20,
                                             hatch=arg_16.hatch,
                                             arg_21=arg_21,  # edgecolour for hatching
                                             **arg_19)
                arg_1.add_patch(arg_23)
            else:
                arg_23 = mpl.patches.Rectangle(arg_15,
                                             arg_18,
                                             arg_17,
                                             arg_20=arg_20,
                                             arg_21=arg_21,  # edgecolour for hatching
                                             **arg_19)
                arg_13.append(arg_23)

        if arg_6 is not None:
            arg_8 = arg_8 or 'viridis'
            arg_24 = mpl.collections.PatchCollection(arg_13, arg_8=arg_8, arg_20=arg_20)
            arg_24.set_array(arg_0.get_data(arg_6, arg_7, arg_9=arg_9))
            arg_1.add_collection(arg_24)
            arg_25 = plt.colorbar(arg_24)  #  orientation='horizontal' only really works with ticks=[0, 0.1, 0.2] say
            arg_25.outline.set_linewidth(0)

        return arg_1

Plotting but only the Rectangles . You have to set up the figure . Returns a matplotlib axis object .


def Func ( arg_0 , arg_1 , arg_2 = arg_3 . pathsep ) : arg_0 . _declare_special ( arg_1 , arg_2 , SetVariable )

def Func(arg_0, arg_1, arg_2=arg_3.pathsep):
        """
        Declare an environment variable as a set-like special variable.
        This can be used even if the environment variable is not
        present.

        :param name: The name of the environment variable that should
                     be considered set-like.
        :param sep: The separator to be used.  Defaults to the value
                    of ``os.pathsep``.
        """

        arg_0._declare_special(arg_1, arg_2, SetVariable)

Declare an environment variable as a set - like special variable . This can be used even if the environment variable is not present .


def Func ( arg_0 , arg_1 = None ) : if arg_1 : arg_1 [ 'compact' ] = True arg_2 = make_get_request ( arg_0 , 'self' , params_data = arg_1 ) arg_3 = arg_2 . json ( ) if arg_2 . status_code == 200 : return arg_3 [ 'result' ] else : raise SelfNotRetrievedException ( message = arg_3 [ 'message' ] , error_code = arg_3 [ 'error_code' ] , request_id = arg_3 [ 'request_id' ] )

def Func(arg_0, arg_1=None):
    """
    Get details about the currently authenticated user
    """
    # Set compact to true
    if arg_1:
        arg_1['compact'] = True
    arg_2 = make_get_request(arg_0, 'self', params_data=arg_1)
    arg_3 = arg_2.json()
    if arg_2.status_code == 200:
        return arg_3['result']
    else:
        raise SelfNotRetrievedException(
            message=arg_3['message'],
            error_code=arg_3['error_code'],
            request_id=arg_3['request_id']
        )


def Func ( arg_0 ) : arg_1 = { } for arg_2 , arg_3 in arg_0 . _fields . iteritems ( ) : arg_4 = getattr ( arg_0 , arg_2 ) if arg_4 is not None : arg_1 [ arg_2 ] = arg_3 . dump ( arg_4 ) return arg_1

def Func(arg_0):
    "Dump record in json-encodable object format"
    arg_1 = {}
    for arg_2, arg_3 in arg_0._fields.iteritems():
        arg_4 = getattr(arg_0, arg_2)
        if arg_4 is not None:
            arg_1[arg_2] = arg_3.dump(arg_4)
    return arg_1

Dump record in json - encodable object format


def Func ( arg_0 ) : arg_1 = [ c . Func ( ) for c in arg_0 . comps ] return arg_0 . field_reduce_func ( arg_1 )

def Func(arg_0):
        """ Combine the fields from all components """
        arg_1 = [c.Func() for c in arg_0.comps]
        return arg_0.field_reduce_func(arg_1)


def Func ( arg_0 , arg_1 = False ) : if arg_1 : return dict ( arg_0 . items ( ) ) else : return { str ( arg_2 ) : arg_3 for arg_2 , arg_3 in arg_0 . items ( ) }

def Func(arg_0, arg_1=False):
        r"""Convert Result to dict.

        Parameters:
            rawkey(bool):
                * True: dict key is Descriptor instance
                * False: dict key is str

        Returns:
            dict

        """
        if arg_1:
            return dict(arg_0.items())
        else:
            return {
                str(arg_2): arg_3
                for arg_2, arg_3 in arg_0.items()
            }


def Func ( arg_0 ) : arg_1 = set ( ) for arg_2 in arg_0 : for arg_3 in arg_2 : if arg_3 != 0 and arg_3 not in arg_1 : yield arg_3 arg_1 . add ( arg_3 )

def Func(arg_0):
    """
    Yields one onset front ID at a time until they are gone. All the onset fronts from a
    frequency channel are yielded, then all of the next channel's, etc., though one at a time.
    """
    arg_1 = set()
    for arg_2 in arg_0:
        for arg_3 in arg_2:
            if arg_3 != 0 and arg_3 not in arg_1:
                yield arg_3
                arg_1.add(arg_3)

Yields one onset front ID at a time until they are gone . All the onset fronts from a frequency channel are yielded then all of the next channel s etc . though one at a time .


def Func ( arg_0 , arg_1 , arg_2 = arg_3 . KMIPVersion . KMIP_1_0 ) : super ( CheckResponsePayload , arg_0 ) . Func ( arg_1 , arg_2 = arg_2 ) arg_6 = utils . BytearrayStream ( arg_1 . Func ( arg_0 . length ) ) if arg_0 . is_tag_next ( arg_3 . Tags . UNIQUE_IDENTIFIER , arg_6 ) : arg_0 . _unique_identifier = primitives . TextString ( tag = arg_3 . Tags . UNIQUE_IDENTIFIER ) arg_0 . _unique_identifier . Func ( arg_6 , arg_2 = arg_2 ) if arg_0 . is_tag_next ( arg_3 . Tags . USAGE_LIMITS_COUNT , arg_6 ) : arg_0 . _usage_limits_count = primitives . LongInteger ( tag = arg_3 . Tags . USAGE_LIMITS_COUNT ) arg_0 . _usage_limits_count . Func ( arg_6 , arg_2 = arg_2 ) if arg_0 . is_tag_next ( arg_3 . Tags . CRYPTOGRAPHIC_USAGE_MASK , arg_6 ) : arg_0 . _cryptographic_usage_mask = primitives . Integer ( tag = arg_3 . Tags . CRYPTOGRAPHIC_USAGE_MASK ) arg_0 . _cryptographic_usage_mask . Func ( arg_6 , arg_2 = arg_2 ) if arg_0 . is_tag_next ( arg_3 . Tags . LEASE_TIME , arg_6 ) : arg_0 . _lease_time = primitives . Interval ( tag = arg_3 . Tags . LEASE_TIME ) arg_0 . _lease_time . Func ( arg_6 , arg_2 = arg_2 ) arg_0 . is_oversized ( arg_6 )

def Func(arg_0, arg_1, arg_2=arg_3.KMIPVersion.KMIP_1_0):
        """
        Read the data encoding the Check response payload and decode it into
        its constituent parts.

        Args:
            input_stream (stream): A data stream containing encoded object
                data, supporting a Func method; usually a BytearrayStream
                object.
            kmip_version (KMIPVersion): An enumeration defining the KMIP
                version with which the object will be decoded. Optional,
                defaults to KMIP 1.0.

        Raises:
            ValueError: Raised if the data attribute is missing from the
                encoded payload.
        """
        super(CheckResponsePayload, arg_0).Func(
            arg_1,
            arg_2=arg_2
        )
        arg_6 = utils.BytearrayStream(arg_1.Func(arg_0.length))

        if arg_0.is_tag_next(arg_3.Tags.UNIQUE_IDENTIFIER, arg_6):
            arg_0._unique_identifier = primitives.TextString(
                tag=arg_3.Tags.UNIQUE_IDENTIFIER
            )
            arg_0._unique_identifier.Func(
                arg_6,
                arg_2=arg_2
            )
        if arg_0.is_tag_next(arg_3.Tags.USAGE_LIMITS_COUNT, arg_6):
            arg_0._usage_limits_count = primitives.LongInteger(
                tag=arg_3.Tags.USAGE_LIMITS_COUNT
            )
            arg_0._usage_limits_count.Func(
                arg_6,
                arg_2=arg_2
            )
        if arg_0.is_tag_next(arg_3.Tags.CRYPTOGRAPHIC_USAGE_MASK, arg_6):
            arg_0._cryptographic_usage_mask = primitives.Integer(
                tag=arg_3.Tags.CRYPTOGRAPHIC_USAGE_MASK
            )
            arg_0._cryptographic_usage_mask.Func(
                arg_6,
                arg_2=arg_2
            )
        if arg_0.is_tag_next(arg_3.Tags.LEASE_TIME, arg_6):
            arg_0._lease_time = primitives.Interval(
                tag=arg_3.Tags.LEASE_TIME
            )
            arg_0._lease_time.Func(
                arg_6,
                arg_2=arg_2
            )

        arg_0.is_oversized(arg_6)

Read the data encoding the Check response payload and decode it into
        its constituent parts.

        Args:
            input_stream (stream): A data stream containing encoded object
                data, supporting a read method; usually a BytearrayStream
                object.
            kmip_version (KMIPVersion): An enumeration defining the KMIP
                version with which the object will be decoded. Optional,
                defaults to KMIP 1.0.

        Raises:
            ValueError: Raised if the data attribute is missing from the
                encoded payload.

Read the data encoding the Check response payload and decode it into its constituent parts .


return requests.delete(self._url, data=self._data, headers=self._headers, auth=(self._email, self._api_token))

def Func ( arg_0 ) : return requests . delete ( arg_0 . _url , data = arg_0 . _data , headers = arg_0 . _headers , auth = ( arg_0 . _email , arg_0 . _api_token ) )

def Func(arg_0):
        """
        HTTP Delete Request
        """
        return requests.delete(arg_0._url, data=arg_0._data, headers=arg_0._headers, auth=(arg_0._email, arg_0._api_token))


def Func(arg_0, arg_1, arg_2):
        """
        Find correct closed dates, if issues was closed by commits.

        :param list issues: issues to check
        :param str kind: either "issues" or "pull requests"
        :rtype: list
        :return: issues with updated closed dates
        """

        if arg_0.options.verbose:
            print("Fetching closed dates for {} {}...".format(
                len(arg_1), arg_2)
            )
        arg_3 = copy.deepcopy(arg_1)
        for arg_4 in arg_3:
            if arg_0.options.verbose > 2:
                print(".", end="")
                if not arg_1.index(arg_4) % 30:
                    print("")
            arg_0.find_closed_date_by_commit(arg_4)

            if not arg_4.get('actual_date', False):
                if arg_4.get('closed_at', False):
                    print("Skipping closed non-merged issue: #{0} {1}".format(
                        arg_4["number"], arg_4["title"]))

                arg_3.remove(arg_4)

        if arg_0.options.verbose > 2:
            print(".")
        return arg_3

Find correct closed dates if issues was closed by commits .


def Func ( arg_0 ) : arg_0 . stream . seek ( arg_0 . start_pos ) return headers . HeaderFactory ( ) . read_from_stream ( arg_0 . stream )

def Func(arg_0):
        """ Reads the head of the las file and returns it
        """
        arg_0.stream.seek(arg_0.start_pos)
        return headers.HeaderFactory().read_from_stream(arg_0.stream)


def Func(arg_0):
        """
        Loads all the data files using the configured finders.
        """
        for arg_1 in arg_0._resources:
            arg_2 = arg_0.load(arg_1)
            yield arg_1, arg_2

        arg_0._resources = []

Loads all the data files using the configured finders .


Return the fields specified in the pattern using Python's
        formatting mini-language.

return [f for f in zip(*parse)[1] if f is not None]

def Func ( arg_0 ) : arg_1 = list ( string . Formatter ( ) . parse ( arg_0 . pattern ) ) return [ arg_2 for arg_2 in zip ( * arg_1 ) [ 1 ] if arg_2 is not None ]

def Func(arg_0):
        """
        Return the Func specified in the pattern using Python's
        formatting mini-language.
        """
        arg_1 = list(string.Formatter().parse(arg_0.pattern))
        return [arg_2 for arg_2 in zip(*arg_1)[1] if arg_2 is not None]

Return the fields specified in the pattern using Python s formatting mini - language .


def Func ( arg_0 , arg_1 ) : if arg_1 . egg_base == os . curdir : return arg_2 = distutils . filelist . findall ( arg_1 . egg_base ) arg_3 = ( os . path . join ( arg_1 . egg_base , path ) for path in arg_2 ) arg_0 . filelist . allfiles . extend ( arg_3 )

def Func(arg_0, arg_1):
        """
        Add paths for egg-info files for an external egg-base.

        The egg-info files are written to egg-base. If egg-base is
        outside the current working directory, this method
        searchs the egg-base directory for files to include
        in the manifest. Uses distutils.filelist.findall (which is
        really the version monkeypatched in by setuptools/__init__.py)
        to perform the search.

        Since findall records relative paths, prefix the returned
        paths with cmd.egg_base, so add_default's include_pattern call
        (which is looking for the absolute cmd.egg_info) will match
        them.
        """
        if arg_1.egg_base == os.curdir:
            # egg-info files were already added by something else
            return

        arg_2 = distutils.filelist.findall(arg_1.egg_base)
        arg_3 = (os.path.join(arg_1.egg_base, path) for path in arg_2)
        arg_0.filelist.allfiles.extend(arg_3)

Add paths for egg - info files for an external egg - base .


def Func(arg_0, arg_1):
    """
    This function gets called when a target is specified to ensure
    that all 'tied' targets also get included in the subgraph to
    be built
    """
    arg_2 = []
    for arg_3 in arg_0:
        for arg_4 in arg_1:
            if arg_3 in arg_4:
                for arg_5 in arg_4:
                    arg_2.append(arg_5)
    arg_2 = list(set(arg_2))
    if arg_2:
        arg_6 = ""
        arg_6 += "The following targets share dependencies and must be run together:"
        for arg_4 in sorted(arg_2):
            arg_6 += "\n  - {}".format(arg_4)
        return list(set(arg_2+arg_0)), arg_6
    return arg_0, ""

This function gets called when a target is specified to ensure that all tied targets also get included in the subgraph to be built


def
Func
(
arg_0
)
:
arg_1
,
arg_2
,
arg_3
=
arg_0
try
:
arg_4
=
get_recovered_variables_for_magbin
(
arg_1
,
arg_3
,
stetson_stdev_min
=
arg_2
[
0
]
,
inveta_stdev_min
=
arg_2
[
1
]
,
iqr_stdev_min
=
arg_2
[
2
]
,
statsonly
=
True
)
return
arg_4
except
Exception
as
e
:
LOGEXCEPTION
(
'failed to get info for %s'
%
arg_2
)
return

def Func(arg_0):
    '''
    This is a parallel grid search worker for the function below.

    '''

    arg_1, arg_2, arg_3 = arg_0

    try:
        arg_4 = get_recovered_variables_for_magbin(arg_1,
                                                 arg_3,
                                                 stetson_stdev_min=arg_2[0],
                                                 inveta_stdev_min=arg_2[1],
                                                 iqr_stdev_min=arg_2[2],
                                                 statsonly=True)
        return arg_4
    except Exception as e:
        LOGEXCEPTION('failed to get info for %s' % arg_2)
        return None

This is a parallel grid search worker for the function below .


def Func ( arg_0 , arg_1 , arg_2 ) : arg_3 = np . zeros ( tm . numberOfColumns ( ) , dtype = "uint32" ) arg_4 = np . zeros ( tm . numberOfColumns ( ) , dtype = "uint32" ) arg_5 = 0 for arg_6 in range ( arg_1 ) : tm . reset ( ) for arg_7 in range ( 4 ) : arg_8 = corruptVector ( arg_0 [ arg_7 ] [ : ] , arg_2 , sparseCols ) tm . compute ( set ( arg_8 [ : ] . nonzero ( ) [ 0 ] . tolist ( ) ) , learn = True ) arg_9 = [ tm . columnForCell ( i ) for i in tm . getActiveCells ( ) ] arg_10 = [ tm . columnForCell ( i ) for i in tm . getPredictiveCells ( ) ] arg_3 = [ 1 if i in arg_9 else 0 for i in range ( tm . numberOfColumns ( ) ) ] arg_11 = accuracy ( arg_3 , arg_4 ) x . append ( arg_5 ) y . append ( arg_11 ) arg_5 += 1 arg_4 = [ 1 if i in arg_10 else 0 for i in range ( tm . numberOfColumns ( ) ) ]

def Func(arg_0, arg_1, arg_2):
  """
  Trains the TM with given sequence for a given number of time steps and level of input
  corruption

  @param sequence   (array) array whose rows are the input characters
  @param timeSteps  (int)   number of time steps in which the TM will be presented with sequence
  @param noiseLevel (float) amount of noise to be applied on the characters in the sequence
  """
  arg_3 = np.zeros(tm.numberOfColumns(), dtype="uint32")
  arg_4 = np.zeros(tm.numberOfColumns(), dtype="uint32")
  arg_5 = 0
  for arg_6 in range(arg_1):
    tm.reset()
    for arg_7 in range(4):
      arg_8 = corruptVector(arg_0[arg_7][:], arg_2, sparseCols)
      tm.compute(set(arg_8[:].nonzero()[0].tolist()), learn=True)
      arg_9 = [tm.columnForCell(i) for i in tm.getActiveCells()]
      arg_10 = [tm.columnForCell(i) for i in tm.getPredictiveCells()]
      arg_3 = [1 if i in arg_9 else 0 for i in range(tm.numberOfColumns())]
      arg_11 = accuracy(arg_3, arg_4)
      x.append(arg_5)
      y.append(arg_11)
      arg_5 += 1
      arg_4 = [1 if i in arg_10 else 0 for i in range(tm.numberOfColumns())]


def Func ( arg_0 , arg_1 ) : arg_2 = { 'file_version' : 2 , 'credentials' : { } } for arg_3 , arg_4 in iteritems ( arg_1 ) : arg_5 = arg_4 . to_json ( ) arg_6 = _helpers . _from_bytes ( base64 . b64encode ( _helpers . _to_bytes ( arg_5 ) ) ) arg_2 [ 'credentials' ] [ arg_3 ] = arg_6 arg_0 . seek ( 0 ) json . dump ( arg_2 , arg_0 ) arg_0 . truncate ( )

def Func(arg_0, arg_1):
    """Writes credentials to a file.

    Refer to :func:`_load_credentials_file` for the format.

    Args:
        credentials_file: An open file handle, must be read/write.
        credentials: A dictionary mapping user-defined keys to an instance of
            :class:`oauth2client.client.Credentials`.
    """
    arg_2 = {'file_version': 2, 'credentials': {}}

    for arg_3, arg_4 in iteritems(arg_1):
        arg_5 = arg_4.to_json()
        arg_6 = _helpers._from_bytes(base64.b64encode(
            _helpers._to_bytes(arg_5)))
        arg_2['credentials'][arg_3] = arg_6

    arg_0.seek(0)
    json.dump(arg_2, arg_0)
    arg_0.truncate()


def Func(arg_0, arg_1):
    """Build a small phenotype object

        Build a dictionary with phenotype_id and description

    Args:
        phenotype_id (str): The phenotype id
        adapter (scout.adapter.MongoAdapter)

    Returns:
        phenotype_obj (dict):

        dict(
            phenotype_id = str,
            feature = str, # description of phenotype
            )
    """
    arg_2 = {}
    arg_3 = arg_1.hpo_term(arg_0)
    if arg_3:
        arg_2['phenotype_id'] = arg_3['hpo_id']
        arg_2['feature'] = arg_3['description']
    return arg_3


def Func ( arg_0 = None , arg_1 = False ) : if arg_0 is None : if not arg_1 : arg_0 = CURRENT_RANDOM_STATE . randint ( SEED_MIN_VALUE , SEED_MAX_VALUE , 1 ) [ 0 ] return np . random . RandomState ( arg_0 )

def Func(arg_0=None, arg_1=False):
    """
    Returns a new random state.

    Parameters
    ----------
    seed : None or int, optional
        Optional seed value to use.
        The same datatypes are allowed as for ``numpy.random.RandomState(seed)``.

    fully_random : bool, optional
        Whether to use numpy's random initialization for the
        RandomState (used if set to True). If False, a seed is sampled from
        the global random state, which is a bit faster and hence the default.

    Returns
    -------
    numpy.random.RandomState
        The new random state.

    """
    if arg_0 is None:
        if not arg_1:
            # sample manually a seed instead of just RandomState(),
            # because the latter one
            # is way slower.
            arg_0 = CURRENT_RANDOM_STATE.randint(SEED_MIN_VALUE, SEED_MAX_VALUE, 1)[0]
    return np.random.RandomState(arg_0)


def Func(arg_0, arg_1):
        """
        Iterate through each member of the class being created and add a
        safety check to every method that isn't marked as read-only.
        """
        for arg_2, arg_3 in arg_1.items():
            arg_1[arg_2] = arg_0.add_safety_check(
                    arg_2, arg_3)

Iterate through each member of the class being created and add a safety check to every method that isn t marked as read - only .


def
Func
(
arg_0
,
arg_1
,
arg_2
)
:
log
.
info
(
"Starting to aggregate remote issues."
)
arg_3
=
aslist
(
arg_0
.
get
(
arg_1
,
'targets'
)
)
arg_4
=
multiprocessing
.
Queue
(
)
log
.
info
(
"Spawning %i workers."
%
len
(
arg_3
)
)
arg_5
=
[
]
if
arg_2
:
for
arg_6
in
arg_3
:
_Func
(
arg_0
,
arg_1
,
arg_6
,
arg_4
,
arg_0
.
get
(
arg_6
,
'service'
)
)
else
:
for
arg_6
in
arg_3
:
arg_7
=
multiprocessing
.
Process
(
arg_6
=
_Func
,
arg_11
=
(
arg_0
,
arg_1
,
arg_6
,
arg_4
,
arg_0
.
get
(
arg_6
,
'service'
)
)
)
arg_7
.
start
(
)
arg_5
.
append
(
arg_7
)
time
.
sleep
(
1
)
arg_8
=
len
(
arg_3
)
while
arg_8
>
0
:
arg_9
=
arg_4
.
get
(
True
)
if
isinstance
(
arg_9
,
tuple
)
:
arg_10
,
arg_11
=
arg_9
if
arg_10
==
SERVICE_FINISHED_ERROR
:
arg_6
,
arg_12
=
arg_11
log
.
info
(
"Terminating workers"
)
for
arg_13
in
arg_5
:
arg_13
.
terminate
(
)
raise
RuntimeError
(
"critical error in target '{}'"
.
format
(
arg_6
)
)
arg_8
-=
1
continue
yield
arg_9
log
.
info
(
"Done aggregating remote issues."
)

def Func(arg_0, arg_1, arg_2):
    """ Return all issues from every target. """
    log.info("Starting to aggregate remote issues.")

    # Create and call service objects for every target in the config
    arg_3 = aslist(arg_0.get(arg_1, 'targets'))

    arg_4 = multiprocessing.Queue()

    log.info("Spawning %i workers." % len(arg_3))
    arg_5 = []

    if arg_2:
        for arg_6 in arg_3:
            _Func(
                arg_0,
                arg_1,
                arg_6,
                arg_4,
                arg_0.get(arg_6, 'service')
            )
    else:
        for arg_6 in arg_3:
            arg_7 = multiprocessing.Process(
                arg_6=_Func,
                arg_11=(arg_0, arg_1, arg_6, arg_4, arg_0.get(arg_6, 'service'))
            )
            arg_7.start()
            arg_5.append(arg_7)

            # Sleep for 1 second here to try and avoid a race condition where
            # all N workers start up and ask the gpg-agent process for
            # information at the same time.  This causes gpg-agent to fumble
            # and tell some of our workers some incomplete things.
            time.sleep(1)

    arg_8 = len(arg_3)
    while arg_8 > 0:
        arg_9 = arg_4.get(True)
        if isinstance(arg_9, tuple):
            arg_10, arg_11 = arg_9
            if arg_10 == SERVICE_FINISHED_ERROR:
                arg_6, arg_12 = arg_11
                log.info("Terminating workers")
                for arg_13 in arg_5:
                    arg_13.terminate()
                raise RuntimeError(
                    "critical error in target '{}'".format(arg_6))
            arg_8 -= 1
            continue
        yield arg_9

    log.info("Done aggregating remote issues.")


def Func(arg_0, arg_1, *arg_2, **arg_3):
        """ Write data to HDF5 file in one go.

        Args:
            filename_out (str): Name of output file
        """

        arg_4 = 0

        with h5py.File(arg_1, 'w') as arg_5:

            arg_5.attrs[b'CLASS']   = b'FILTERBANK'
            arg_5.attrs[b'VERSION'] = b'1.0'

            if HAS_BITSHUFFLE:
                arg_7 = bitshuffle.h5.H5FILTER
                arg_8 = (arg_4, bitshuffle.h5.H5_COMPRESS_LZ4)
            else:
                arg_7 = None
                arg_8 = None
                logger.warning("Warning: bitshuffle not found. No compression applied.")

            arg_9 = arg_5.create_dataset('data',
                        data=arg_0.data,
#                          compression='lzf')
                        compression=arg_7,
                        compression_opts=arg_8)

            arg_10 = arg_5.create_dataset('mask',
                        shape=arg_0.file_shape,
#                                 compression='lzf',
                        compression=arg_7,
                        compression_opts=arg_8,
                        dtype='uint8')

            arg_9.dims[0].label = b"frequency"
            arg_9.dims[1].label = b"feed_id"
            arg_9.dims[2].label = b"time"

            arg_10.dims[0].label = b"frequency"
            arg_10.dims[1].label = b"feed_id"
            arg_10.dims[2].label = b"time"

            # Copy over header information as attributes
            for arg_13, arg_14 in arg_0.header.items():
                arg_9.attrs[arg_13] = arg_14


def Func ( arg_0 , arg_1 , arg_2 ) : arg_3 = set ( [ gene [ 'hgnc_id' ] for gene in arg_1 [ 'genes' ] ] ) arg_4 = set ( [ gene [ 'hgnc_id' ] for gene in arg_2 [ 'genes' ] ] ) return arg_4 . difference ( arg_3 )

def Func(arg_0, arg_1, arg_2):
        """Check if the latest version of OMIM differs from the most recent in database
           Return all genes that where not in the previous version.

        Args:
            existing_panel(dict)
            new_panel(dict)

        Returns:
            new_genes(set(str))
        """
        arg_3 = set([gene['hgnc_id'] for gene in arg_1['genes']])
        arg_4 = set([gene['hgnc_id'] for gene in arg_2['genes']])

        return arg_4.difference(arg_3)

Check if the latest version of OMIM differs from the most recent in database Return all genes that where not in the previous version .


def Func ( arg_0 , arg_1 ) : arg_2 = _adsDLL . AdsAddRoute arg_2 . restype = ctypes . c_long arg_4 = ctypes . c_char_p ( arg_1 . encode ( "utf-8" ) ) arg_5 = arg_2 ( arg_0 , arg_4 ) if arg_5 : raise ADSError ( arg_5 )

def Func(arg_0, arg_1):
    # type: (SAmsNetId, str) -> None
    """Establish a new route in the AMS Router.

    :param pyads.structs.SAmsNetId net_id: net id of routing endpoint
    :param str ip_address: ip address of the routing endpoint

    """
    arg_2 = _adsDLL.AdsAddRoute
    arg_2.restype = ctypes.c_long

    # Convert ip address to bytes (PY3) and get pointer.
    arg_4 = ctypes.c_char_p(arg_1.encode("utf-8"))

    arg_5 = arg_2(arg_0, arg_4)

    if arg_5:
        raise ADSError(arg_5)

Establish a new route in the AMS Router .


def Func ( arg_0 = 0 ) : with Frame ( arg_0 = arg_0 ) as frame : arg_1 = frame . f_locals return arg_1

def Func(arg_0=0):
    """Returns locals dictionary from a given frame.

    :param int stepback:

    :rtype: dict

    """
    with Frame(arg_0=arg_0) as frame:
        arg_1 = frame.f_locals

    return arg_1

Returns locals dictionary from a given frame .


def Func ( arg_0 , arg_1 ) : ActionChains ( arg_0 . driver ) . key_down ( arg_1 ) . key_up ( Keys . CONTROL ) . perform ( )

def Func(arg_0, arg_1):
        """
            Works around the problem of emulating user interactions with text inputs.
            Emulates a key-down action on the first char of the input. This way, implementations which
            require key-down event to trigger auto-suggest are testable.
            Then the chains sends the rest of the text and releases the key.
        """
        ActionChains(arg_0.driver).key_down(arg_1).key_up(Keys.CONTROL).perform()

Works around the problem of emulating user interactions with text inputs . Emulates a key - down action on the first char of the input . This way implementations which require key - down event to trigger auto - suggest are testable . Then the chains sends the rest of the text and releases the key .


def Func ( arg_0 ) : arg_1 = arg_0 . index ( ) if arg_1 != None : del arg_0 . canvas . layers [ arg_1 ]

def Func(arg_0):

        """Removes this layer from the canvas.

        """

        arg_1 = arg_0.index()
        if arg_1 != None: del arg_0.canvas.layers[arg_1]


def Func ( arg_0 , arg_1 ) : _check_cols ( arg_0 , [ arg_1 ] ) arg_2 = arg_0 [ pd . notnull ( arg_0 [ arg_1 ] ) & arg_0 . duplicated ( subset = [ arg_1 ] ) ] return arg_2

def Func(arg_0, arg_1):
    """ Return a DataFrame with the duplicated values of the column `col_name`
    in `df`."""
    _check_cols(arg_0, [arg_1])

    arg_2 = arg_0[pd.notnull(arg_0[arg_1]) & arg_0.duplicated(subset=[arg_1])]
    return arg_2

Return a DataFrame with the duplicated values of the column col_name in df .


def
Func
(
arg_0
)
:
if
not
arg_0
.
require_3D
:
arg_0
.
fail
(
AttributeError
(
"use 3D Funcinate in 2D descriptor"
)
)
return
arg_0
.
_context
.
get_Func
(
arg_0
)

def Func(arg_0):
        """Get 3D Funcinate.

        Returns:
            numpy.array[3, N]: Funcinate matrix

        """
        if not arg_0.require_3D:
            arg_0.fail(AttributeError("use 3D Funcinate in 2D descriptor"))

        return arg_0._context.get_Func(arg_0)

Get 3D coordinate.

        Returns:
            numpy.array[3, N]: coordinate matrix


def Func ( * arg_0 , ** arg_1 ) : arg_2 = list ( arg_0 ) arg_2 . append ( arg_1 ) arg_3 = { } for arg_4 in arg_2 : for arg_5 , arg_6 in arg_4 . items ( ) : if arg_6 is not None : arg_3 [ arg_5 ] = arg_6 return arg_3

def Func(*arg_0, **arg_1):
    """Creates a dict with the inputted items; pruning any that are `None`.

    Args:
        *dictionaries(dict): Dictionaries of items to be pruned and included.
        **items: Items to be pruned and included.

    Returns:
        dict: A dictionary containing all of the items with a 'non-None' value.

    """
    arg_2 = list(arg_0)
    arg_2.append(arg_1)
    arg_3 = {}
    for arg_4 in arg_2:
        for arg_5, arg_6 in arg_4.items():
            if arg_6 is not None:
                arg_3[arg_5] = arg_6
    return arg_3

Creates a dict with the inputted items ; pruning any that are None .