(obj, sdc_header_flag=False)
return lines
Returns short description for a given object obj

    :param obj: Object for which short description needs to be returned
    :param sdc_header_flag: Flag indicating that the first three lines must be considered as Intel SDC header
    :return: String, short description
    :raises: NameError, when ``sdc_header_flag==True`` and no Intel SDC header section found.
        The header is expected to be 4 lines long, where the first three lines are of the form:
            Intel Scalable Dataframe Compiler User Guide
            ********************************************
            Pandas API: <pandas API name>
        The fourth line must be empty
Returns short description for a given object obj
Returns short description for a given object obj
def get_short_description(obj, sdc_header_flag=False):
    """
    Returns short description for a given object obj

    :param obj: Object for which short description needs to be returned
    :param sdc_header_flag: Flag indicating that the first three lines must be considered as Intel SDC header
    :return: String, short description
    :raises: NameError, when ``sdc_header_flag==True`` and no Intel SDC header section found.
        The header is expected to be 4 lines long, where the first three lines are of the form:
            Intel Scalable Dataframe Compiler User Guide
            ********************************************
            Pandas API: <pandas API name>
        The fourth line must be empty

    """
    doc = get_docstring(obj)
    if doc == '':
        return doc

    sections = split_in_sections(doc)  # tuple (title, text)

    if sdc_header_flag:
        if len(sections) > 1:  # There must be at least one more section after Intel SDC header section
            if not is_sdc_user_guide_header(sections[0]):
                raise NameError('No Intel SDC header section found')

            sections.pop(0)  # Ignore Intel SDC header section

    if len(sections) == 0:
        return ''  # Docstring has no sections, i.e. short description is absent

    title, text = sections[0]  # Short description is the first section of the docstring
    text = text.strip()
    lines = text.split('\n')
    lines = [line.strip() for line in lines]
    lines = ' '.join(lines)

    return lines
def get_short_description ( obj , sdc_header_flag = False ) : doc = get_docstring ( obj ) if doc == '' : return doc sections = split_in_sections ( doc ) # tuple (title, text) if sdc_header_flag : if len ( sections ) > 1 : # There must be at least one more section after Intel SDC header section if not is_sdc_user_guide_header ( sections [ 0 ] ) : raise NameError ( 'No Intel SDC header section found' ) sections . pop ( 0 ) # Ignore Intel SDC header section if len ( sections ) == 0 : return '' # Docstring has no sections, i.e. short description is absent title , text = sections [ 0 ] # Short description is the first section of the docstring text = text . strip ( ) lines = text . split ( '\n' ) lines = [ line . strip ( ) for line in lines ] lines = ' ' . join ( lines ) return lines