Recherche avancée

Médias (91)

Autres articles (54)

  • Menus personnalisés

    14 novembre 2010, par

    MediaSPIP utilise le plugin Menus pour gérer plusieurs menus configurables pour la navigation.
    Cela permet de laisser aux administrateurs de canaux la possibilité de configurer finement ces menus.
    Menus créés à l’initialisation du site
    Par défaut trois menus sont créés automatiquement à l’initialisation du site : Le menu principal ; Identifiant : barrenav ; Ce menu s’insère en général en haut de la page après le bloc d’entête, son identifiant le rend compatible avec les squelettes basés sur Zpip ; (...)

  • Les vidéos

    21 avril 2011, par

    Comme les documents de type "audio", Mediaspip affiche dans la mesure du possible les vidéos grâce à la balise html5 .
    Un des inconvénients de cette balise est qu’elle n’est pas reconnue correctement par certains navigateurs (Internet Explorer pour ne pas le nommer) et que chaque navigateur ne gère en natif que certains formats de vidéos.
    Son avantage principal quant à lui est de bénéficier de la prise en charge native de vidéos dans les navigateur et donc de se passer de l’utilisation de Flash et (...)

  • (Dés)Activation de fonctionnalités (plugins)

    18 février 2011, par

    Pour gérer l’ajout et la suppression de fonctionnalités supplémentaires (ou plugins), MediaSPIP utilise à partir de la version 0.2 SVP.
    SVP permet l’activation facile de plugins depuis l’espace de configuration de MediaSPIP.
    Pour y accéder, il suffit de se rendre dans l’espace de configuration puis de se rendre sur la page "Gestion des plugins".
    MediaSPIP est fourni par défaut avec l’ensemble des plugins dits "compatibles", ils ont été testés et intégrés afin de fonctionner parfaitement avec chaque (...)

Sur d’autres sites (9208)

  • Stream RAW8 video from camera using openCV and Python [Windows]

    14 novembre 2022, par awin

    We have a camera that streams RAW8 video at 1920x1080. The GUID used is GREY. We are able to stream video from this camera using ffmpeg on Windows with the below command :

    


    ffmpeg -f dshow -pix_fmt gray -video_size 1920x1080 -i video="CAM0" -f nut - | ffplay -


    


    We are now trying to grab images from this camera using OpenCV using the below code snippet, but its unable to grab any frame (frame_grabbed is always false)

    


    import cv2
import numpy as np

# reading the video from CAM0
source = cv2.VideoCapture(1)

height = 1920
width = 1080

source.set(cv2.CAP_PROP_FRAME_WIDTH, width)
source.set(cv2.CAP_PROP_FRAME_HEIGHT, height)


image = np.zeros([height, width, 3], np.uint8)

while True:
    # Extracting the frames
    frame_grabbed , image = source.read()

    if (frame_grabbed ):
        colour1 = cv2.cvtColor(image, cv2.COLOR_BayerRG2BGR)
        cv2.imshow("Demosaiced image", colour1)
    else:
        print("No images grabbed")

#Exit on q
    key = cv2.waitKey(1)
    if key == ord("q"):
       break

# closing the window
cv2.destroyAllWindows()
source.release()



    


    Are we missing something here ?

    


    We then came across this post to pipe ffmpeg output to python (link). However, when we are passing the command as below :

    


    command = [ 'ffmpeg.exe',
            '-f', 'dshow',
            '-i', 'video="CAM0"',
            '-pix_fmt', 'gray',
            '-video_size','1920x1080'
            '-f', 'nut', '-']


    


    its throwing

    


    


    Could not find video device with name ["CAM0"] among source devices
of type video. video="CAM0" : I/O error

    


    


    I have verified that the camera is present using the below command :

    


    command = [ 'ffmpeg.exe',
            '-list_devices', 'true',
            '-f', 'dshow',
            '-i', 'dummy']


    


    This detects CAM0 as shown below :

    


    ffmpeg version 5.0.1-full_build-www.gyan.dev Copyright (c) 2000-2022 the FFmpeg developers
  built with gcc 11.2.0 (Rev7, Built by MSYS2 project)
  configuration: --enable-gpl --enable-version3 --enable-static --disable-w32threads --disable-autodetect --enable-fontconfig --enable-iconv --enable-gnutls --enable-libxml2 --enable-gmp --enable-bzlib --enable-lzma --enable-libsnappy --enable-zlib --enable-librist --enable-libsrt --enable-libssh --enable-libzmq --enable-avisynth --enable-libbluray --enable-libcaca --enable-sdl2 --enable-libdav1d --enable-libdavs2 --enable-libuavs3d --enable-libzvbi --enable-librav1e --enable-libsvtav1 --enable-libwebp --enable-libx264 --enable-libx265 --enable-libxavs2 --enable-libxvid --enable-libaom --enable-libopenjpeg --enable-libvpx --enable-mediafoundation --enable-libass --enable-frei0r --enable-libfreetype --enable-libfribidi --enable-liblensfun --enable-libvidstab 
--enable-libvmaf --enable-libzimg --enable-amf --enable-cuda-llvm --enable-cuvid --enable-ffnvcodec --enable-nvdec --enable-nvenc --enable-d3d11va --enable-dxva2 --enable-libmfx --enable-libshaderc --enable-vulkan --enable-libplacebo --enable-opencl --enable-libcdio --enable-libgme --enable-libmodplug --enable-libopenmpt --enable-libopencore-amrwb --enable-libmp3lame --enable-libshine --enable-libtheora --enable-libtwolame --enable-libvo-amrwbenc --enable-libilbc --enable-libgsm --enable-libopencore-amrnb --enable-libopus --enable-libspeex --enable-libvorbis --enable-ladspa --enable-libbs2b --enable-libflite --enable-libmysofa --enable-librubberband --enable-libsoxr --enable-chromaprint
  libavutil      57. 17.100 / 57. 17.100
  libavcodec     59. 18.100 / 59. 18.100
  libavformat    59. 16.100 / 59. 16.100
  libavdevice    59.  4.100 / 59.  4.100
  libavfilter     8. 24.100 /  8. 24.100
  libswscale      6.  4.100 /  6.  4.100
  libswresample   4.  3.100 /  4.  3.100
  libpostproc    56.  3.100 / 56.  3.100
[dshow @ 000001ea39e40600] "HP HD Camera" (video)
[dshow @ 000001ea39e40600]   Alternative name "@device_pnp_\\?\usb#vid_04f2&pid_b6bf&mi_00#6&1737142c&0&0000#{65e8773d-8f56-11d0-a3b9-00a0c9223196}\global"
[dshow @ 000001ea39e40600] "CAM0" (video)
[dshow @ 000001ea39e40600]   Alternative name "@device_pnp_\\?\usb#vid_0400&pid_0011&mi_00#7&1affbd5b&0&0000#{65e8773d-8f56-11d0-a3b9-00a0c9223196}\global"


    


    In short, we are able to capture video using ffmpeg commandline, but unable to grab any frame using OpenCV videocapture or ffmpeg in opencv. Any pointers ?

    


    Thanks !

    


  • Couldn't find ffmpeg or avconv - Python

    18 juin 2024, par goldie

    I'm working on a captcha solver and I need to use ffmpeg, though nothing works. Windows 10 user.

    


    Warning when running the code for the first time :

    


    C:\Users\user\AppData\Roaming\Python\Python310\site-packages\pydub\utils.py:170: RuntimeWarning: Couldn't find ffmpeg or avconv - defaulting to ffmpeg, but may not work
  warn("Couldn't find ffmpeg or avconv - defaulting to ffmpeg, but may not work", RuntimeWarning)


    


    Then, when I tried running the script anyway and it required ffprobe, I got the following error :

    


    C:\Users\user\AppData\Roaming\Python\Python310\site-packages\pydub\utils.py:198: RuntimeWarning: Couldn&#x27;t find ffprobe or avprobe - defaulting to ffprobe, but may not work&#xA;  warn("Couldn&#x27;t find ffprobe or avprobe - defaulting to ffprobe, but may not work", RuntimeWarning)&#xA;Traceback (most recent call last):&#xA;  File "D:\Scripts\captcha\main.py", line 164, in <module>&#xA;    main()&#xA;  File "D:\Scripts\captcha\main.py", line 155, in main&#xA;    captchaSolver()&#xA;  File "D:\Scripts\captcha\main.py", line 106, in captchaSolver&#xA;    sound = pydub.AudioSegment.from_mp3(&#xA;  File "C:\Users\user\AppData\Roaming\Python\Python310\site-packages\pydub\audio_segment.py", line 796, in from_mp3&#xA;    return cls.from_file(file, &#x27;mp3&#x27;, parameters=parameters)&#xA;  File "C:\Users\user\AppData\Roaming\Python\Python310\site-packages\pydub\audio_segment.py", line 728, in from_file&#xA;    info = mediainfo_json(orig_file, read_ahead_limit=read_ahead_limit)&#xA;  File "C:\Users\user\AppData\Roaming\Python\Python310\site-packages\pydub\utils.py", line 274, in mediainfo_json&#xA;    res = Popen(command, stdin=stdin_parameter, stdout=PIPE, stderr=PIPE)&#xA;  File "C:\Program Files\Python310\lib\subprocess.py", line 966, in __init__&#xA;    self._execute_child(args, executable, preexec_fn, close_fds,&#xA;  File "C:\Program Files\Python310\lib\subprocess.py", line 1435, in _execute_child&#xA;    hp, ht, pid, tid = _winapi.CreateProcess(executable, args,&#xA;FileNotFoundError: [WinError 2] The system cannot find the file specified&#xA;</module>

    &#xA;

    I tried downloading it normally, editing environment variables, pasting them in the same folder as the script, installing with pip, tested ffmpeg manually to see if it works and indeed it converted a mkv to mp4, however my script has no intention of running

    &#xA;

  • Protecting consumer privacy : How to ensure CCPA compliance

    18 août 2023, par Erin — CCPA, Privacy

    The California Consumer Privacy Act (CCPA) is a state law that enhances privacy rights and consumer protection for residents of California. 

    It grants consumers six rights, like the right to know what personal information is being collected about them by businesses and others. 

    CCPA also requires businesses to provide notice of data collection practices. Consumers can choose to opt out of the sale of their data. 

    In this article, we’ll learn more about the scope of CCPA, the penalties for non-compliance and how our web analytics tool, Matomo, can help you create a CCPA-compliant framework.

    What is the CCPA ? 

    CCPA was implemented on January 1, 2020. It ensures that businesses securely handle individuals’ personal information and respect their privacy in the digital ecosystem. 

    How does CCPA compliance add value

    CCPA addresses the growing concerns over privacy and data protection ; 40% of US consumers share that they’re worried about digital privacy. With the increasing amount of personal information being collected and shared by businesses, there was a need to establish regulations to provide individuals with more control and transparency over their data. 

    CCPA aims to protect consumer privacy rights and promote greater accountability from businesses when handling personal information.

    Scope of CCPA 

    The scope of CCPA includes for-profit businesses that collect personal information from California residents, regardless of where you run the business from.

    It defines three thresholds that determine the inclusion criteria for businesses subject to CCPA regulations. 

    Businesses need to abide by CCPA if they meet any of the three options :

    1. Revenue threshold : Have an annual gross revenue of over $25 million.
    2. Consumer threshold : Businesses that purchase, sell or distribute the personal information of 100,000 or more consumers, households or devices.
    3. Data threshold : Businesses that earn at least half of their revenue annually from selling the personal information of California residents.

    What are the six consumer rights under the CCPA ? 

    Here’s a short description of the six consumer rights. 

    The six rights of consumers under CCPA
    1. Right to know : Under this right, you can ask a business to disclose specific personal information they collect about you and the categories of sources of the information. You can also know the purpose of collection and to which third-party the business will disclose this info. This allows consumers to understand what information is being held and how it is used. You can request this info for free twice a year.
    2. Right to delete : Consumers can request the deletion of their personal information. Companies must comply with some exceptions.
    3. Right to opt-out : Consumers can deny the sale of their personal information. Companies must provide a link on their homepage for users to exercise this right. After you choose this, companies can’t sell your data unless you authorise them to do so later.
    4. Right to non-discrimination : Consumers cannot be discriminated against for exercising their CCPA rights. For instance, a company cannot charge different prices, provide a different quality of service or deny services.
    5. Right to correct : Consumers can request to correct inaccurate personal information.

    6. Right to limit use : Consumers can specify how they want the businesses to use their sensitive personal information. This includes social security numbers, financial account details, precise geolocation data or genetic data. Consumers can direct businesses to use this sensitive information only for specific purposes, such as providing the requested services.

    Penalties for CCPA non-compliance 

    52% of organisations have yet to adopt CCPA principles as of 2022. Non-compliance can attract penalties.

    Section 1798.155 of the CCPA states that any business that doesn’t comply with CCPA’s terms can face penalties based on the consumer’s private right to action. Consumers can directly take the company to the civil court and don’t need prosecutors’ interventions. 

    Businesses get a chance of 30 days to make amends for their actions. 

    If that’s also not possible, the business may receive a civil penalty of up to $2,500 per violation. Violations can be of any kind, even accidental. An intentional violation can attract a fine of $7,500. 

    Consumers can also initiate private lawsuits to claim damages that range from $100 to $750, or actual damages (whichever is higher), for each occurrence of their unredacted and unencrypted data being breached on a business’s server.

    CCPA vs. GDPR 

    Both CCPA and GDPR aim to enhance individuals’ control over their personal information and provide transparency about how their data is collected, used and shared. The comparison between the CCPA and GDPR is crucial in understanding the regulatory framework of data protection laws.

    Here’s how CCPA and GDPR differ :

    Scope

    • CCPA is for businesses that meet specific criteria and collect personal information from California residents. 
    • GDPR (General Data Protection Regulation) applies to businesses that process the personal data of citizens and residents of the European Union.

    Definition of personal information

    • CCPA includes personal information broadly, including identifiers such as IP addresses and households. Examples include name, email id, location and browsing history. However, it excludes HIPAA-protected medical data, clinical trial data and other personal information from government records.
    • GDPR covers any personal data relating to an identified or identifiable individual, excluding households. Examples include the phone number, email address and personal identification number. It excludes anonymous and deceased person’s data.
    Personal information definition under CCPA and GDPR

    Consent

    • Under the CCPA, consumers can opt out of the sale of their personal information.
    • GDPR states that organisations should obtain explicit consent from individuals for processing their personal data.

    Rights

    • CCPA grants the right to know what personal information is being collected and the right to request deletion of their personal information.
    • GDPR also gives individuals various rights, such as the right to access and rectify their personal data, the right to erasure (also known as the right to be forgotten) and also the right to data portability. 

    Enforcement

    • For CCPA, businesses may have to pay $7,500 for each violation. 
    • GDPR has stricter penalties for non-compliance, with fines of up to 4% of the global annual revenue of a company or €20 million, whichever is higher.

    A 5-step CCPA compliance framework 

    Here’s a simple framework you can follow to ensure compliance with CCPA. Alongside this, we’ll also share how Matomo can help. 

    Matomo is an open-source web analytics platform trusted by organisations like the United Nations, NASA and more. It provides valuable insights into website traffic, visitor behaviour and marketing effectiveness. More than 1 million websites and apps (approximately 1% of the internet !) use our solution, and it’s available in 50+ languages. Below, we’ll share how you can use Matomo to be CCPA compliant.

    1. Assess data

    First, familiarise yourself with the California Consumer Privacy Act and check your eligibility for CCPA compliance. 

    For example, as mentioned earlier, one threshold is : purchases, receives or sells the personal data of 100,000 or more individuals or households

    But how do you know if you have crossed 100K ? With Matomo ! 

    Go to last year’s calendar, select visitors, then go to locations and under the “Region” option, check for California. If you’ve crossed 100K visitors, you know you have to become CCPA compliant.

    View geolocation traffic details in Matomo

    Identify and assess the personal information you collect with Matomo.

    2. Evaluate privacy practices

    Review the current state of your privacy policies and practices. Conduct a thorough assessment of data sharing and third-party agreements. Then, update policies and procedures to align with CCPA requirements.

    For example, you can anonymise IP addresses with Matomo to ensure that user data collected for web analytics purposes cannot be used to trace back to specific individuals.

    Using Matomo to anonymize visitors' IP addresses

    If you have a consent management solution to honour user requests for data privacy, you can also integrate Matomo with it. 

    3. Communicate 

    Inform consumers about their CCPA rights and how you handle their data.

    Establish procedures for handling consumer requests and obtaining consent. For example, you can add an opt-out form on your website with Matomo. Or you can also use Matomo to disable cookies from your website.

    Screenshot of a command line disabling cookies

    Documenting your compliance efforts, including consumer requests and how you responded to them, is a good idea. Finally, educate staff on CCPA compliance and their responsibilities to work collaboratively.

    4. Review vendor contracts

    Assessing vendor contracts allows you to determine if they include necessary data processing agreements. You can also identify if vendors are sharing personal information with third parties, which could pose a compliance risk. Verify if vendors have adequate security measures in place to protect the personal data they handle.

    That’s why you can review and update agreements to include provisions for data protection, privacy and CCPA requirements.

    Establish procedures to monitor and review vendor compliance with CCPA regularly. This may include conducting audits, requesting certifications and implementing controls to mitigate risks associated with vendors handling personal data.

    5. Engage legal counsel

    Consider consulting with legal counsel to ensure complete understanding and compliance with CCPA regulations.

    Finally, stay updated on any changes or developments related to CCPA and adjust your compliance efforts accordingly.

    Matomo and CCPA compliance 

    There’s an increasing emphasis on privacy regulations like CCPA. Matomo offers a robust solution that allows businesses to be CCPA-compliant without sacrificing the ability to track and analyse crucial data.

    You can gain in-depth insights into user behaviour and website performance — all while prioritising data protection and privacy. 

    Request a demo or sign up for a free 21-day trial to get started with our powerful CCPA-compliant web analytics platform — no credit card required. 

    Disclaimer

    We are not lawyers and don’t claim to be. The information provided here is to help give an introduction to CCPA. We encourage every business and website to take data privacy seriously and discuss these issues with your lawyer if you have any concerns.