Recherche avancée

Médias (0)

Mot : - Tags -/diogene

Aucun média correspondant à vos critères n’est disponible sur le site.

Autres articles (84)

  • Le profil des utilisateurs

    12 avril 2011, par

    Chaque utilisateur dispose d’une page de profil lui permettant de modifier ses informations personnelle. Dans le menu de haut de page par défaut, un élément de menu est automatiquement créé à l’initialisation de MediaSPIP, visible uniquement si le visiteur est identifié sur le site.
    L’utilisateur a accès à la modification de profil depuis sa page auteur, un lien dans la navigation "Modifier votre profil" est (...)

  • Configurer la prise en compte des langues

    15 novembre 2010, par

    Accéder à la configuration et ajouter des langues prises en compte
    Afin de configurer la prise en compte de nouvelles langues, il est nécessaire de se rendre dans la partie "Administrer" du site.
    De là, dans le menu de navigation, vous pouvez accéder à une partie "Gestion des langues" permettant d’activer la prise en compte de nouvelles langues.
    Chaque nouvelle langue ajoutée reste désactivable tant qu’aucun objet n’est créé dans cette langue. Dans ce cas, elle devient grisée dans la configuration et (...)

  • XMP PHP

    13 mai 2011, par

    Dixit Wikipedia, XMP signifie :
    Extensible Metadata Platform ou XMP est un format de métadonnées basé sur XML utilisé dans les applications PDF, de photographie et de graphisme. Il a été lancé par Adobe Systems en avril 2001 en étant intégré à la version 5.0 d’Adobe Acrobat.
    Étant basé sur XML, il gère un ensemble de tags dynamiques pour l’utilisation dans le cadre du Web sémantique.
    XMP permet d’enregistrer sous forme d’un document XML des informations relatives à un fichier : titre, auteur, historique (...)

Sur d’autres sites (6929)

  • The new GDPR data protection regulation and potential consequences on Piwik

    7 septembre 2017, par Piwik Core Team — About, Privacy

    GDPR is a new data protection related regulation in Europe. GDPR stands for General Data Protection Regulation.

    The purpose of this European regulation is to strengthen and unify data protection for all individuals within the European Union. This also includes entities outside Europe willing to do business with European citizens. GDPR is a set of processes you need to follow within your organization to protect the privacy of European citizens.

    GDPR will start to apply in May 2018. It is recognized to be dissuasive because of the potential penalty of up to 4% of the yearly turnover, in case of infringement.

    Many articles have been written about GDPR including our previous article. Few of them are explaining how it will affect web analytics vendors : this is what this article is about.

    Am I really impacted by GDPR if I am a Piwik user ?

    As Piwik can collect personal data, the answer is yes. Piwik analytics data is impacted by the GDPR.

    As GDPR is a general concept, we decided from the official guidelines to assume what will be the potential consequences on the use of Piwik.

    There are 2 potential scenarios we can identify :

    • 1 – You are collecting personal data with Piwik
    • 2 – You are not collecting personal data with Piwik

    1 – Personal data collection with Piwik

    According to GDPR : IP addresses, cookies, UserID are personal data.

    IP addresses are personal data, so you will have to anonymize them unless you receive explicit consent from the visitor. Please view the following article in order to learn : how can I anonymize IP addresses in Piwik ?

    According to GDPR, cookies are personal data too. But as all cookies are not created equal it may be possible that some need to require user consent whereas other not. Whatever will be the final decision, you can learn about the first-party cookies created by Piwik and how to disable all tracking cookies in Piwik ?

    User ID, you are impacted if the User ID you assign is specific to an individual or if you can cross the User ID data further and find back the individual personal data.

    Any extra personal data you may collect with Piwik, it could be for example : first names, family names, e-mail address… You are able to collect such data using custom dimensions, custom variables…

    What are the rules I have to comply with ?

    By collecting personal data, you will have to respect EU citizens rights, which include :

    • The possibility for them to view the data you collected on them
    • The possibility to rectify some data concerning them
    • The possibility to delete their data when they request about it

    As you can imagine, for the first obligation, you will have to export all the data. So if a user is requesting it, you will have to export the data linked to his IP address(es). It can be easily exported as a .csv file for example.
    In order to do that, just create a segment according to the IP address of the user who requested it and then export the “Visitor log” report.
    If the personal data is not linked with the IP address but other attributes such as User ID or a custom dimension, you can provide the same data export by using the segment function and filtering on the personal data field.

    The data edit and deletion process on Piwik is a bit trickier as it currently requires administration system skills. We are planning to develop a new plugin for GDPR compliance (which will be available for free on the Marketplace). This plugin will let you edit and easily delete data of a particular user. Currently you can delete a specific user’s data by accessing the Piwik database and directly delete the different records for this specific user.

    2 – You are not collecting personal data with Piwik

    Unfortunately it is not because you do not collect personal data that you will not be affected by GDPR.
    The details of GDPR are not confirmed yet and GDPR could involve enabling the DoNotTrack setting by default on all browsers.
    Yes, you read it well, by default, unless the internet user uncheck this option, Piwik respecting DoNoTrack would not be able to track any user. If one needed to collect data anyway, Piwik Log Analytics and server-side tracking can be considered.

    If you need help regarding how to set up your Piwik installation in order to be GDPR compliant :

    Do you have a Piwik experience you would like to share with the community ? Please share it with us by contacting Piwik core team.

  • ffmpeg 4.4 problem with image2 combined with stream loop -1 and overlay

    14 mai 2021, par codeSam

    I have a python app and my code to stream ffmpeg is :

    


    'ffmpeg',
'-thread_queue_size', '1024',
'-i', 'rtsp://...',
'-f', 'image2',
'-stream_loop', '-1',
'-i', 'image.png',
'-filter_complex', 'overlay=(main_w-overlay_w)/2:main_h*0.1-overlay_h',
'-acodec', 'aac',
'-ar', '44100',
'-ab', '128k',
'-f', 'flv',
'-g', '30',
'-vcodec', 'libx264',
'-preset', 'ultrafast',
'-crf', '30',
'rtmp://...'


    


    Works fine on ffmpeg 4.3.2. But after ffmpeg updated to 4.4 the stream doesn't start at all. If I change stream_loop -1 to loop 1 the stream starts but as I want to update the image.png like every 10 seconds or so, it stops being updated on the stream. That is probably because new image.png is being saved at the same time it is being read. stream_loop doesn't mind this as I have understood.

    


    Also if I delay image.png start with -ss -5, the stream starts with main video from rtsp ://... but it stops when image.png starts to be read.

    


    Also if I remove -f image2 from the code, the stream starts fine but image.png is not being updated to the stream.

    


    Would be easy to downgrade ffmpeg to the older 4.3.2 version but it is not possible as I want this thing to run on Android device in Termux. Termux has only the latest ffmpeg 4.4 available.

    


    Any ideas how to make this work on ffmpeg 4.4.

    


    Here is what is printed out when I run the command above. The stream does not start. This is done with Termux in Android device. Stream does not start in my Mac Book Pro's ffmpeg 4.4 either, in that 4.3.2 is ok.

    


    ffmpeg version 4.4 Copyright (c) 2000-2021 the FFmpeg developers
  built with Android (6454773 based on r365631c2) clang version 9.0.8 
(https://android.googlesource.com/toolchain/llvm-project 98c855489587874b2a325e7a516b99d838599c6f) (based on LLVM 9.0.8svn)
  configuration: --arch=aarch64 --as=aarch64-linux-android-clang --cc=aarch64-linux-android-clang
  --cxx=aarch64-linux-android-clang++ --cross-prefix=aarch64-linux-android- --disable-indevs 
  --disable-outdevs --enable-indev=lavfi --disable-static --disable-symver --enable-cross-compile 
  --enable-gnutls --enable-gpl --enable-libass --enable-libdav1d --enable-libmp3lame 
  --enable-libfreetype --enable-libvorbis --enable-libopus --enable-libx264 --enable-libx265 
  --enable-libxvid --enable-libvpx --enable-shared --enable-libsoxr --enable-libvidstab 
  --enable-libwebp --prefix=/data/data/com.termux/files/usr --target-os=android 
  --extra-libs=-landroid-glob --enable-neon
  libavutil      56. 70.100 / 56. 70.100
  libavcodec     58.134.100 / 58.134.100
  libavformat    58. 76.100 / 58. 76.100
  libavdevice    58. 13.100 / 58. 13.100
  libavfilter     7.110.100 /  7.110.100
  libswscale      5.  9.100 /  5.  9.100
  libswresample   3.  9.100 /  3.  9.100
  libpostproc    55.  9.100 / 55.  9.100
[udp @ 0x7ebe823840] 'circular_buffer_size' option was set but it is not supported on this build (pthread support is required)
[udp @ 0x7ebe8238e0] 'circular_buffer_size' option was set but it is not supported on this build (pthread support is required)
[udp @ 0x7ebe823a20] 'circular_buffer_size' option was set but it is not supported on this build (pthread support is required)
[udp @ 0x7ebe823ac0] 'circular_buffer_size' option was set but it is not supported on this build (pthread support is required)

Guessed Channel Layout for Input Stream #0.1 : mono
Input #0, rtsp, from 'rtsp://...':
  Metadata:
    title           : Session streamed by "TP-LINK RTSP Server"
    comment         : stream1
  Duration: N/A, start: 0.000000, bitrate: N/A
  Stream #0:0: Video: h264 (High), yuvj420p(pc, bt709, progressive), 1920x1080, 15 fps, 15 tbr, 90k tbn, 30 tbc
  Stream #0:1: Audio: pcm_alaw, 8000 Hz, mono, s16, 64 kb/s
Input #1, image2, from 'image.png':
  Duration: 00:00:00.04, start: 0.000000, bitrate: N/A
  Stream #1:0: Video: png, rgba(pc), 1152x87 [SAR 8504:8504 DAR 384:29], 25 fps, 25 tbr, 25 tbn, 25 tbc
Stream mapping:
  Stream #0:0 (h264) -> overlay:main (graph 0)
  Stream #1:0 (png) -> overlay:overlay (graph 0)
  overlay (graph 0) -> Stream #0:0 (libx264)
  Stream #0:1 -> #0:1 (pcm_alaw (native) -> aac (native))
Press [q] to stop, [?] for help


    


  • ffmpeg : video to images with pts in filename

    12 février 2016, par ntg

    I am trying to extract images of exact times (say every second) from a mp4 video of an experiment. There are a lot of methods to do that using ffmpeg out there, but surprisingly enough the time accuracy is off.

    To measure accuracy, I have first time-stamped the video using pts, e.g. :

    -vf "[in] scale=640:-2 , drawtext=fontcolor=white:fontsize=22:fontfile='times.ttf':timecode='22\:10\:55\:00:text='03/12/15__':r=23.976023976:x=0:y=0 [out]"

    And as a result I got a millisecond precision time-stamp on the video. I checked the video and it seems the time-stamps are very accurate. I then tried all the methods I could find out there including :

    -Using -ss [timestamp] to go to an exact time and -vframes 1 to get the first frame at that time : this method is extremely slow since it involves calling ffmpeg once for each second of the video. Furthermore, seems to work fine for the first minutes, but then gets out of sync.

    -Using fps=1 and using out_%05d.jpg as the output. This was probably the most inaccurate, as it went off by whole seconds, plus it never got exactly the 0th millisecond.

    -Using a fast fps, and then selecting only the ones I need, e.g. -vf "fps=10, framestep=10, select=not(mod(n\,40))" was promising for the first minutes, but also became inaccurate after that.

    -I tried writing the pts/date as metadata, but (do not know how to /cannot) write to the metadata of a .jpg from ffmpeg...

    The problem is that after some time, if we are using out_%05d.jpg, the numbers get completely out of sinc, while the -ss gets inaccurate, and takes forever.

    Ideally there should be a way to write the %pts or the date as part of the filename... Does anyone know a method to extract images from an .mp4 file with millisecond precision, preferably using ffmpeg (or its library ? I am using python and getting desperate...)

    [Edit : as explained in the comment by Mulvya, the pts is calculated by using the fps of the video, ffmpeg can give it to you. In my case some of the videos have 30 and others 24*(100/1001) fps. Bellow is an example, which was produced by :

    args = ['ffmpeg',
    '-i',
    'c:\\Temp\\scr_cam.mp4',
    '-y',
    '-vf',
    "[in] drawtext=fontcolor=black:fontsize=22:fontfile='times.ttf':timecode='17\\:00\\:29\\:00':text='09/02/16__':r=30.0:x=0:y=0, drawtext=fontcolor=black:fontsize=22:fontfile='times.ttf':timecode='00\\:00\\:00\\:00':text='':r=30.0 :x=0:y=30, drawtext=fontcolor=black:fontsize=22:fontfile='times.ttf':text='n\\: %{n}   pts\\:%{pts}':r=30.0:x=0:y=60 [out]",
    '-c:a',
    'copy',
    '-metadata',
    'creation_time=2016-02-09T17:00:29',
    '-preset',
    'ultrafast',
    '-threads',
    '3',
    'c:\\Temp\\stamped_scr_cam.mp4']
    subprocess.call(args)

    In it we see that indeed pts = n/30 (n is the frame no). I have tried many combinations of the params of the commands I talk in the beginning, so listing all my efforts would take too much space. As we see, the drawtext seems to be very accurate, so it does not seem to be a problem of incorrect fps.

    sample of drawtext

    To get the fps I am using :

    def get_frame_rate_and_duration(filename):
       if not os.path.exists(filename):
           sys.stderr.write("ERROR: filename %r was not found!" % (filename,))
           return -1
       args = ["ffprobe",filename,"-v","0","-select_streams","v","-print_format","flat"]
       args.extend(["-show_entries","stream=r_frame_rate"])
       args.extend(["-show_entries","format=duration"])
       out = subprocess.check_output(args).split("\n")
       rate = out[0].split('=')[1].strip()[1:-1].split('/')
       duration = pd.Timedelta("{0} sec".format(out[1].split('=')[1].strip()[1:-1]))
       if len(rate)==1:
           rate = float(rate[0])
       if len(rate)==2:
           rate =  float(rate[0])/float(rate[1])
       else:
           rate = -1
       return rate, duration