From dd70d155fb83d61ec735888df1fd06ded5b9ae35 Mon Sep 17 00:00:00 2001
From: 游雁 <zhifu.gzf@alibaba-inc.com>
Date: 星期二, 14 二月 2023 19:06:52 +0800
Subject: [PATCH] Merge branch 'main' of github.com:alibaba-damo-academy/FunASR add

---
 .github/workflows/main.yml          |   11 ++++++++++-
 funasr/datasets/iterable_dataset.py |    4 ++--
 README.md                           |    4 ++--
 3 files changed, 14 insertions(+), 5 deletions(-)

diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml
index cfb94f3..d6158a7 100644
--- a/.github/workflows/main.yml
+++ b/.github/workflows/main.yml
@@ -14,6 +14,10 @@
       - uses: actions/checkout@v1
       - uses: ammaraskar/sphinx-action@master
         with:
+          docs-folder: "docs/"
+          pre-build-command: "pip install sphinx-markdown-tables nbsphinx jinja2 recommonmark sphinx_rtd_theme"
+      - uses: ammaraskar/sphinx-action@master
+        with:
           docs-folder: "docs_cn/"
           pre-build-command: "pip install sphinx-markdown-tables nbsphinx jinja2 recommonmark sphinx_rtd_theme"
 
@@ -22,7 +26,12 @@
         run: |
           mkdir public
           touch public/.nojekyll
-          cp -r docs_cn/_build/html/* public/
+          mkdir public/en
+          touch public/en/.nojekyll
+          cp -r docs/_build/html/* public/en/
+          mkdir public/cn
+          touch public/cn/.nojekyll
+          cp -r docs_cn/_build/html/* public/cn/
 
       - name: deploy github.io pages
         if: github.ref == 'refs/heads/main' || github.ref == 'refs/heads/dev'
diff --git a/README.md b/README.md
index 3f63c6b..2e08de8 100644
--- a/README.md
+++ b/README.md
@@ -7,7 +7,7 @@
 [**News**](https://github.com/alibaba-damo-academy/FunASR#whats-new) 
 | [**Highlights**](#highlights)
 | [**Installation**](#installation)
-| [**Docs**](https://alibaba-damo-academy.github.io/FunASR/index.html)
+| [**Docs**](https://alibaba-damo-academy.github.io/FunASR/cn/index.html)
 | [**Tutorial**](https://github.com/alibaba-damo-academy/FunASR/wiki#funasr%E7%94%A8%E6%88%B7%E6%89%8B%E5%86%8C)
 | [**Papers**](https://github.com/alibaba-damo-academy/FunASR#citations)
 | [**Runtime**](https://github.com/alibaba-damo-academy/FunASR/tree/main/funasr/runtime)
@@ -42,7 +42,7 @@
 For more details, please ref to [installation](https://github.com/alibaba-damo-academy/FunASR/wiki)
 
 ## Usage
-For users who are new to FunASR and ModelScope, please refer to [FunASR Docs](https://alibaba-damo-academy.github.io/FunASR/index.html).
+For users who are new to FunASR and ModelScope, please refer to [FunASR Docs](https://alibaba-damo-academy.github.io/FunASR/cn/index.html).
 
 ## Contact
 
diff --git a/funasr/datasets/iterable_dataset.py b/funasr/datasets/iterable_dataset.py
index 2001df9..2f97e78 100644
--- a/funasr/datasets/iterable_dataset.py
+++ b/funasr/datasets/iterable_dataset.py
@@ -224,7 +224,7 @@
                 name = self.path_name_type_list[i][1]
                 _type = self.path_name_type_list[i][2]
                 if _type == "sound":
-                    audio_type = os.path.basename(value).split(".")[1].lower()
+                    audio_type = os.path.basename(value).split(".")[-1].lower()
                     if audio_type not in SUPPORT_AUDIO_TYPE_SETS:
                         raise NotImplementedError(
                             f'Not supported audio type: {audio_type}')
@@ -326,7 +326,7 @@
                 # 2.a. Load data streamingly
                 for value, (path, name, _type) in zip(values, self.path_name_type_list):
                     if _type == "sound":
-                        audio_type = os.path.basename(value).split(".")[1].lower()
+                        audio_type = os.path.basename(value).split(".")[-1].lower()
                         if audio_type not in SUPPORT_AUDIO_TYPE_SETS:
                             raise NotImplementedError(
                                 f'Not supported audio type: {audio_type}')

--
Gitblit v1.9.1