2019/04/07
-
파이썬 프로그램을 실행하던 도중 아래와 같은 에러에 직면하였습니다. 에러명 UnsupportedOperation : not readable 해결방법 r+ 모드로 옵션을 변경합니다. 파일을 여는 것(open)과 관련된 함수를 찾아서, r+ 옵션을 부여하였고 인코딩 utf8을 입력하였습니다. with open(config.metadata_path, mode='r+', encoding='utf8') as f: 예제 file = open("File.txt","r") 옵션 "r" Opens a file for reading only. "r+" Opens a file for both reading and writing. "rb" Opens a file for reading only in binary format. ..
7. UnsupportedOperation : not readable파이썬 프로그램을 실행하던 도중 아래와 같은 에러에 직면하였습니다. 에러명 UnsupportedOperation : not readable 해결방법 r+ 모드로 옵션을 변경합니다. 파일을 여는 것(open)과 관련된 함수를 찾아서, r+ 옵션을 부여하였고 인코딩 utf8을 입력하였습니다. with open(config.metadata_path, mode='r+', encoding='utf8') as f: 예제 file = open("File.txt","r") 옵션 "r" Opens a file for reading only. "r+" Opens a file for both reading and writing. "rb" Opens a file for reading only in binary format. ..
2019.04.07 -
음성합성을 진행하다보면 alignment.json에 음성과 텍스트를 쌍을 저장하기 위해서 아래의 명령어를 실행할 때가 있다. python -m recognition.alignment --recognition_path "./datasets/son/recognition.json" --score_threshold=0.5 --recognition_encoding="utf-8" 상황에 따라 다를 수도 있겠지만, 인코딩 이슈 또는 IndexError list index out of range에러를 만날 것이다. 인코딩 이슈를 만났을 경우 에러명 : UnicodeDecodeError: 'cp949' codec can't decode byte 0xec in position 51: illegal multibyte seq..
6. [음성합성] IndexError list index out of range 해결음성합성을 진행하다보면 alignment.json에 음성과 텍스트를 쌍을 저장하기 위해서 아래의 명령어를 실행할 때가 있다. python -m recognition.alignment --recognition_path "./datasets/son/recognition.json" --score_threshold=0.5 --recognition_encoding="utf-8" 상황에 따라 다를 수도 있겠지만, 인코딩 이슈 또는 IndexError list index out of range에러를 만날 것이다. 인코딩 이슈를 만났을 경우 에러명 : UnicodeDecodeError: 'cp949' codec can't decode byte 0xec in position 51: illegal multibyte seq..
2019.04.07 -
파이썬에서 except를 사용하려면 try와 함께 사용해야합니다. try없이 except를 사용하였을 경우 SyntaxError : Invalid syntax라는 에러를 만나게 됩니다. 감사합니다.
[pyton] except Invalid syntax파이썬에서 except를 사용하려면 try와 함께 사용해야합니다. try없이 except를 사용하였을 경우 SyntaxError : Invalid syntax라는 에러를 만나게 됩니다. 감사합니다.
2019.04.07