Recherche avancée

Médias (1)

Mot : - Tags -/wave

Autres articles (51)

Sur d’autres sites (8296)

  • codecs.ascii_decode(input, self.errors)[0] UnicodeDecodeError : 'ascii' codec can't decode byte 0xc2 in position 318 : ordinal not in range(128)

    6 janvier 2017, par dtidy

    I am trying to open and readlines a .txt file that contains a large amount of text. Below is my code, i dont know how to solve this problem. Any help would be very appreciated.

    file = input("Please enter a .txt file: ")
    myfile = open(file)
    x = myfile.readlines()
    print (x)

    when i enter the .txt file this is the full error message is displayed below :

    line 10, in <module> x = myfile.readlines()
    line 26, in decode return codecs.ascii_decode(input, self.errors)[0]
    UnicodeDecodeError: 'ascii' codec can't decode byte 0xc2 in position 318: ordinal not in range(128)
    </module>
  • Building OpenCV 2.4.11 on Linux with `libopencv_ffmpeg.so`

    28 décembre 2016, par SomethingSomething

    When downloading OpenCV sources, no matter whether it is for Windows or for Linux, the sources directory contains only the Windows already-compiled shared library 3rdparty/ffmpeg/opencv_ffmpeg.dll, that is essential for the VideoCapture module to work on the Python portings for OpenCV.

    In Linux, as this file is not provided, you’d expect it to be automatically built when you build OpenCV, especially when in CMakeCache.txt, you can spot the line WITH_FFMPEG:BOOL=ON.

    It is of course not built... Any idea ?

  • use AForge.Video.FFMPEG.dll to grab video thumbnail

    5 avril 2015, par Sean

    I am using AForge.Video.FFMPEG.dll to grab video thumbnail on website, it will be shown on webpage or other clients. I downloaded latest version of the dll and related native library into /bin folder and copied to system32 folder as well.

    but when I compiled the project, it will told me :
    "
    Could not load file or assembly ’AForge.Video.FFMPEG.DLL’ or one of its dependencies. The specified module could not be found.
    "

    1. I copied all DLLs
      enter image description here

    2. All DLLs are 32bit, not x64 bit.

    3. I saw another article to introduce how to load native c or managed c++ library in asp.net, but doesn’t work for me.
      http://blogs.msdn.com/b/jorman/archive/2007/08/31/loading-c-assemblies-in-asp-net.aspx

    4. My developing environment : Windows2012R2 VS2010

    5. When I was compiling the project, compiler will throw above exception.

    Thanks,

    Sean