2017-12-15 1 views
0

스테 가노 그라피를 처음 사용합니다. 테스트를하려고하는데이 오류가 발생합니다.스테 가노 그래피 오류 - 'hex'는 텍스트 인코딩이 아닙니다. codecs.encode()를 사용하여 임의의 코덱 처리

'hex' is not a text encoding; use codecs.encode() to handle arbitrary codecs 

나는이 문서를 binascii에 대해 읽었지만 어떻게 만들 수 있습니까?

내 코드는 하나입니다

from __future__ import absolute_import, unicode_literals 
from steganography.steganography import Steganography 

path = "/Users/cohen/Desktop/Screenshot_030.png" 
output_path = "/Users/cohen/Desktop/output_steganography.png" 

text = "/Users/cohen/Desktop/test.txt" 

Steganography.encode(path, output_path, text) #---here is the line with error 

감사합니다!

+0

프로젝트 관리자에게 Python 3에서 작동하도록 코드를 업데이트하거나 Python 2에서만 사용하도록 요청할 수 있습니다. –

+0

프로젝트는 현재 Python 3과 호환되지 않습니다. –

+0

감사합니다! 나는 그것들이 그들의 코드에 비린내가있는 것이라고 가르쳤다. – Cohen

답변

1

실제로 나는 또한 확인했습니다. 이 프로젝트는 파이썬 3과 호환되지 않습니다.

특히 LSB (Least Significant Bit) 기술을 테스트하려는 경우 GitHub에서 멋진 스테 가노 그래피 모듈을 많이 사용할 수 있습니다. 예를 들어이 코드는 Python 3과 호환됩니다. https://github.com/cedricbonhomme/Stegano

관련 문제