Internal function that is used for generation of the GitHub and PyPI README file.

    ----------
    Parameters
    ----------
    notebook_object : notebook object
        Object of "notebook" class where the body will be created.

    dict_by_tag : dict
        Dictionary where each key is a tag and the respective value will be a list containing the
        Notebooks (title and filename) that include this tag.

def _generate_github_readme(notebook_object, dict_by_tag):
    """
    Internal function that is used for generation of the GitHub and PyPI README file.

    ----------
    Parameters
    ----------
    notebook_object : notebook object
        Object of "notebook" class where the body will be created.

    dict_by_tag : dict
        Dictionary where each key is a tag and the respective value will be a list containing the
        Notebooks (title and filename) that include this tag.

    """

    # ==================== List of urls that contain each Category icon ============================
    icons = {"Detect": "https://i.ibb.co/rymrvFL/Detect.png",
             "Evaluate": "https://i.ibb.co/yfwcy2M/Evaluate.png",
             "Extract": "https://i.ibb.co/tchq7Cc/Extract.png",
             "Load": "https://i.ibb.co/YPbCnzD/Load.png",
             "Pre-Process": "https://i.ibb.co/1rKWccX/Pre-Process.png",
             "Record": "https://i.ibb.co/d2jZH1s/Record.png",
             "Train_and_Classify": "https://i.ibb.co/CQ4cyGb/Train-and-Classify.png",
             "Understand": "https://i.ibb.co/MnhRRQT/Understand.png",
             "Visualise": "https://i.ibb.co/wh4HKzf/Visualise.png",
             "Other": "https://i.ibb.co/ry9BzhV/Other.png",
             "Install": "https://i.ibb.co/4fBR4Q3/Install.png",
             "Connect": "https://i.ibb.co/3yDZpxC/Connect.png"}

    # =========================== biosignalsnotebooks website ======================================
    biosignalsnotebooks_web = "http://www.biosignalsplux.com/notebooks/Categories/"

    # == Generation of a table that group Notebooks by category the information about each signal ==
    category_list = list(NOTEBOOK_KEYS.keys())
    tag_keys = list(dict_by_tag.keys())

    markdown_cell = """<table width="100%">
    <tr>
        <td width="20%" align="center"><strong> Category <strong></td>
        <td width="80%"></td>
    </tr>"""

    for i, category in enumerate(category_list):
        if category != "MainFiles":
            if category.lower() in tag_keys:
                nbr_notebooks = len(dict_by_tag[category.lower()])
                notebook_list = dict_by_tag[category.lower()]
                split_path = notebook_list[0].replace("\\", "/").split("/")
                notebook_name = split_path[-1].split("&")[0]
                notebook_title = split_path[-1].split("&")[1]
                markdown_cell += "\n\t<tr>" \
                                 "\n\t\t<td rowspan='" + str(nbr_notebooks) + "'><p align='center'><img src='" + icons[category] + "' width='50%' align='center'></p></td>" \
                                 "\n\t\t<td align='center'> <a href='" + biosignalsnotebooks_web + category + "/" + notebook_name.replace(".ipynb", "_rev.php") + "' target='_blank'>" + notebook_title + "</a> </td>" \
                                 "\n\t</tr>"

                for j, notebook_file in enumerate(notebook_list[1:]):
                    split_path = notebook_file.replace("\\", "/").split("/")
                    notebook_name = split_path[-1].split("&")[0]
                    notebook_title = split_path[-1].split("&")[1]
                    markdown_cell += "\n\t<tr>" \
                                     "\n\t\t<td align='center'> <a href='" + biosignalsnotebooks_web + category + "/" + notebook_name.replace(".ipynb", "_rev.php") + "'>" + notebook_title + "</a> </td>" \
                                     "\n\t</tr>"

    markdown_cell += "\n</table>"

    # ============================ Generation of README files ======================================
    # [Open template]
    template_path = os.path.abspath(__file__).split(os.path.basename(__file__))[0].replace("\\", "/") + "/notebook_files/github/README_TEMPLATE.md"
    with open(template_path, 'r') as readme:
        readme_str = readme.read()

    readme_str = readme_str.replace("LIST_OF_NOTEBOOKS", markdown_cell)

    # [Storage of the updated files]
    for path in ["../biosignalsnotebooks/README_BSN.md", "../README.md"]:
        with open(path, 'w') as readme_out:
            readme_out.write(readme_str)
        readme_out.close()