Recherche avancée

Médias (91)

Autres articles (30)

  • Creating farms of unique websites

    13 avril 2011, par

    MediaSPIP platforms can be installed as a farm, with a single "core" hosted on a dedicated server and used by multiple websites.
    This allows (among other things) : implementation costs to be shared between several different projects / individuals rapid deployment of multiple unique sites creation of groups of like-minded sites, making it possible to browse media in a more controlled and selective environment than the major "open" (...)

  • Publier sur MédiaSpip

    13 juin 2013

    Puis-je poster des contenus à partir d’une tablette Ipad ?
    Oui, si votre Médiaspip installé est à la version 0.2 ou supérieure. Contacter au besoin l’administrateur de votre MédiaSpip pour le savoir

  • Configuration spécifique d’Apache

    4 février 2011, par

    Modules spécifiques
    Pour la configuration d’Apache, il est conseillé d’activer certains modules non spécifiques à MediaSPIP, mais permettant d’améliorer les performances : mod_deflate et mod_headers pour compresser automatiquement via Apache les pages. Cf ce tutoriel ; mode_expires pour gérer correctement l’expiration des hits. Cf ce tutoriel ;
    Il est également conseillé d’ajouter la prise en charge par apache du mime-type pour les fichiers WebM comme indiqué dans ce tutoriel.
    Création d’un (...)

Sur d’autres sites (6179)

  • ffmpeg mp4 to mp3 conversion generates 1 second audio files only [closed]

    24 janvier 2024, par doesnotcompile

    I am having the following problem : I am having trouble converting an mp4 to an mp3.

    


    I have mp4 audio recordings that I need to convert in to mp3 audio files. The mp4 files have been recorded on iOS.

    


    I am currently doing this by using ffmpeg in python like so :

    


    subprocess.run(
            [
                "ffmpeg",
                "-loglevel", "error",
                "-i", ,
                "-q:a", "0",
                "-map", "a",
                
            ]
        )


    


    This runs with no error outputs.

    


    However, the resulting mp3 is only 1 second long, even though the input mp4 is around 5 seconds long.

    


    The mp4 is playable in Quicktime and Apple Music.

    


    ffprobe output :

    


    > ffprobe -v error -show_format input.mp4
[FORMAT]
filename=input.mp4
nb_streams=1
nb_programs=0
format_name=mov,mp4,m4a,3gp,3g2,mj2
format_long_name=QuickTime / MOV
start_time=0.000000
duration=5.120000
size=119636
bit_rate=186931
probe_score=100
TAG:major_brand=iso5
TAG:minor_version=1
TAG:compatible_brands=isomiso5hlsf
TAG:creation_time=2024-01-24T12:47:24.000000Z
[/FORMAT]


    


    No errors shown, and clearly 5 seconds long audio.

    


    Has anyone else experienced similar issues before ?

    


    Happy about any pointers !

    


  • Error : Output format mp4 is not available

    12 avril 2024, par alpaca pwaa

    I'm using fluent-ffmpeg in my nextjs application, I'm trying to process the video and specified a format to stream on my s3 bucket but it keeps on failing. My terminal keeps on throwing "Error : Error : Output format mp4 is not available". I already verify my ffmpeg format "ffmpeg -format" and confirm that it supports encoding and decoding mp4 files. I've already tried solutions from other forums but it's not working for me.

    


    createVideo: privateProcedure
    .input(
      z.object({
        fileId: z.string(),
      })
    )
    .mutation(async ({ ctx, input }) => {
      const { getUser } = getKindeServerSession();
      const user = await getUser();

      if (!user || !user.id || !user.email) {
        throw new TRPCError({ code: "UNAUTHORIZED" });
      }

      const dbUser = await db.user.findFirst({
        where: {
          id: user.id,
        },
      });

      if (!dbUser) {
        throw new TRPCError({
          code: "UNAUTHORIZED",
          message: "User not found in the database.",
        });
      }

      const putObjectCommand = new PutObjectCommand({
        Bucket: process.env.AWS_BUCKET_NAME!,
        Key: generateFileName(),
      });

      const s3 = new S3Client({
        region: process.env.AWS_BUCKET_REGION!,
        credentials: {
          accessKeyId: process.env.AWS_ACCESS_KEY!,
          secretAccessKey: process.env.AWS_SECRET_ACCESS_KEY!,
        },
      });

      const singedURL = await getSignedUrl(s3, putObjectCommand, {
        expiresIn: 60,
      });

      const ffmpeg = require("fluent-ffmpeg");
      const passthroughStream = new PassThrough();

      ffmpeg({ source: "./template1.mp4" })
        .on("end", async () => {
          console.log("Job done");
          await uploadToS3(passthroughStream);
        })
        .on("error", (error: string) => {
          console.error("Error:", error);
          throw new Error("Error processing video");
        })
        .videoFilter({
          filter: "drawtext",
          options: {
            text: "hi",
            fontsize: 24,
            fontcolor: "white",
            x: "(w-text_w)/2",
            y: "(h-text_h)/2",
            box: 1,
            boxcolor: "black@0.5",
            boxborderw: 5,
            fontfile: "/Windows/fonts/calibri.ttf",
          },
        })
        .videoCodec("libx264")
        .outputFormat("mp4")
        .outputOptions(["-movflags frag_keyframe+empty_moov"])
        .pipe(passthroughStream, { end: true });

      const uploadToS3 = async (stream: PassThrough) => {
        const upload = new Upload({
          client: s3,
          params: {
            Bucket: process.env.AWS_BUCKET_NAME!,
            Key: generateFileName(),
            Body: stream,
          },
        });
        await upload.done();
      };

      await new Promise((resolve, reject) => {
        passthroughStream.on("end", resolve);
        passthroughStream.on("error", reject);
      });

      const createdVideo = await db.video.create({
        data: {
          name: "Test Name",
          url: singedURL.split("?")[0],
          key: singedURL,
          fileId: input.fileId,
        },
      });

      return createdVideo;
    }),


    


    Here's the ffmpeg log.

    


    ffmpeg started on 2024-04-11 at 20:58:56
Report written to "ffmpeg-20240411-205856.log"
Log level: 48
Command line:
"C:\\ProgramData\\chocolatey\\lib\\ffmpeg-full\\tools\\ffmpeg\\bin\\ffmpeg.exe" -i ./template1.mp4 -filter:v "drawtext=text=hi:fontsize=24:fontcolor=white:x=(w-text_w)/2:y=(h-text_h)/2:box=1:boxcolor=black@0.5:boxborderw=5:fontfile=/Windows/fonts/calibri.ttf" -report pipe:1
ffmpeg version 7.0-full_build-www.gyan.dev Copyright (c) 2000-2024 the FFmpeg developers
  built with gcc 13.2.0 (Rev5, 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-libaribb24 --enable-libaribcaption --enable-libdav1d --enable-libdavs2 --enable-libuavs3d --enable-libxevd --enable-libzvbi --enable-librav1e --enable-libsvtav1 --enable-libwebp --enable-libx264 --enable-libx265 --enable-libxavs2 --enable-libxeve --enable-libxvid --enable-libaom --enable-libjxl --enable-libopenjpeg --enable-libvpx --enable-mediafoundation --enable-libass --enable-frei0r --enable-libfreetype --enable-libfribidi --enable-libharfbuzz --enable-liblensfun --enable-libvidstab --enable-libvmaf --enable-libzimg --enable-amf --enable-cuda-llvm --enable-cuvid --enable-dxva2 --enable-d3d11va --enable-d3d12va --enable-f  libavutil      59.  8.100 / 59.  8.100
  libavcodec     61.  3.100 / 61.  3.100
  libavformat    61.  1.100 / 61.  1.100
  libavdevice    61.  1.100 / 61.  1.100
  libavfilter    10.  1.100 / 10.  1.100
  libswscale      8.  1.100 /  8.  1.100
  libswresample   5.  1.100 /  5.  1.100
  libpostproc    58.  1.100 / 58.  1.100
Splitting the commandline.
Reading option '-i' ... matched as input url with argument './template1.mp4'.
Reading option '-filter:v' ... matched as option 'filter' (apply specified filters to audio/video) with argument 'drawtext=text=hi:fontsize=24:fontcolor=white:x=(w-text_w)/2:y=(h-text_h)/2:box=1:boxcolor=black@0.5:boxborderw=5:fontfile=/Windows/fonts/calibri.ttf'.
Reading option '-report' ... matched as option 'report' (generate a report) with argument '1'.
Reading option 'pipe:1' ... matched as output url.
Finished splitting the commandline.
Parsing a group of options: global .
Applying option report (generate a report) with argument 1.
Successfully parsed a group of options.
Parsing a group of options: input url ./template1.mp4.
Successfully parsed a group of options.
Opening an input file: ./template1.mp4.
[AVFormatContext @ 00000262cd0888c0] Opening './template1.mp4' for reading
[file @ 00000262cd0a94c0] Setting default whitelist 'file,crypto,data'
[mov,mp4,m4a,3gp,3g2,mj2 @ 00000262cd0888c0] Format mov,mp4,m4a,3gp,3g2,mj2 probed with size=2048 and score=100
[mov,mp4,m4a,3gp,3g2,mj2 @ 00000262cd0888c0] ISO: File Type Major Brand: isom
[mov,mp4,m4a,3gp,3g2,mj2 @ 00000262cd0888c0] Unknown dref type 0x206c7275 size 12
[mov,mp4,m4a,3gp,3g2,mj2 @ 00000262cd0888c0] Processing st: 0, edit list 0 - media time: 1024, duration: 126981
[mov,mp4,m4a,3gp,3g2,mj2 @ 00000262cd0888c0] Offset DTS by 1024 to make first pts zero.
[mov,mp4,m4a,3gp,3g2,mj2 @ 00000262cd0888c0] Setting codecpar->delay to 2 for stream st: 0
[mov,mp4,m4a,3gp,3g2,mj2 @ 00000262cd0888c0] Before avformat_find_stream_info() pos: 6965 bytes read:32768 seeks:0 nb_streams:1
[h264 @ 00000262cd0bb140] nal_unit_type: 7(SPS), nal_ref_idc: 3
[h264 @ 00000262cd0bb140] Decoding VUI
[h264 @ 00000262cd0bb140] nal_unit_type: 8(PPS), nal_ref_idc: 3
[h264 @ 00000262cd0bb140] nal_unit_type: 7(SPS), nal_ref_idc: 3
[h264 @ 00000262cd0bb140] Decoding VUI
[h264 @ 00000262cd0bb140] nal_unit_type: 8(PPS), nal_ref_idc: 3
[h264 @ 00000262cd0bb140] Decoding VUI
[h264 @ 00000262cd0bb140] nal_unit_type: 6(SEI), nal_ref_idc: 0
[h264 @ 00000262cd0bb140] nal_unit_type: 7(SPS), nal_ref_idc: 3
[h264 @ 00000262cd0bb140] nal_unit_type: 8(PPS), nal_ref_idc: 3
[h264 @ 00000262cd0bb140] nal_unit_type: 5(IDR), nal_ref_idc: 3
[h264 @ 00000262cd0bb140] Decoding VUI
[h264 @ 00000262cd0bb140] Format yuv420p chosen by get_format().
[h264 @ 00000262cd0bb140] Reinit context to 1088x1920, pix_fmt: yuv420p
[h264 @ 00000262cd0bb140] no picture 
[mov,mp4,m4a,3gp,3g2,mj2 @ 00000262cd0888c0] All info found
[mov,mp4,m4a,3gp,3g2,mj2 @ 00000262cd0888c0] After avformat_find_stream_info() pos: 82242 bytes read:82242 seeks:0 frames:1
Input #0, mov,mp4,m4a,3gp,3g2,mj2, from './template1.mp4':
  Metadata:
    major_brand     : isom
    minor_version   : 512
    compatible_brands: isomiso2avc1mp41
    encoder         : Lavf58.76.100
  Duration: 00:00:08.27, start: 0.000000, bitrate: 3720 kb/s
  Stream #0:0[0x1](und), 1, 1/15360: Video: h264 (High) (avc1 / 0x31637661), yuv420p(tv, bt709, progressive), 1080x1920, 3714 kb/s, 30 fps, 30 tbr, 15360 tbn (default)
      Metadata:
        handler_name    : VideoHandler
        vendor_id       : [0][0][0][0]
Successfully opened the file.
Parsing a group of options: output url pipe:1.
Applying option filter:v (apply specified filters to audio/video) with argument drawtext=text=hi:fontsize=24:fontcolor=white:x=(w-text_w)/2:y=(h-text_h)/2:box=1:boxcolor=black@0.5:boxborderw=5:fontfile=/Windows/fonts/calibri.ttf.
Successfully parsed a group of options.
Opening an output file: pipe:1.
[AVFormatContext @ 00000262cd0b2240] Unable to choose an output format for 'pipe:1'; use a standard extension for the filename or specify the format manually.
[out#0 @ 00000262cd0bb300] Error initializing the muxer for pipe:1: Invalid argument
Error opening output file pipe:1.
Error opening output files: Invalid argument
[AVIOContext @ 00000262cd0a9580] Statistics: 82242 bytes read, 0 seeks


    


    I should be able to stream the processed video to my s3, but it keeps on throwing "Error : Error : Output format mp4 is not available"

    


  • 16 Website Metrics to Track If You Want to Grow Your Business

    9 avril 2024, par Erin

    Conversion rate.

    Bounce rate.

    Sessions.

    There are dozens of metrics to keep up with in web analytics. It can be confusing at times trying to keep up with everything.

    But, if you want to improve your website performance and grow your business, you need to know what they are and how they work.

    Why ?

    Because what you measure gets managed. This is true in your personal life and business. You must track various website metrics to help your business reach new heights.

    In this guide, you’ll learn about the most important website metrics, why they’re important and how to track them to grow your brand.

    What are website metrics ?

    Your website is your digital headquarters.

    It’s not a static place. Instead, it’s a vibrant, interactive hub your visitors and customers can engage with daily.

    Every time a user interacts with your website, you can track what’s happening.

    Website metrics help you measure how much your visitors and customers interact with your website. 

    These engagement metrics help you understand what your visitors are doing, where they’re coming from, how they’re moving on your website and how long they stay. They can even give you insights into what their goals are.

    What are website metrics?

    If you aren’t tracking your website metrics, you won’t know how effective your website is.

    By paying close attention to your key metrics within a web analytics platform like Matomo, you’ll be able to see how well your marketing is doing and how your visitors are engaging so you can improve the user experience and increase conversions.

    16 website metrics to track

    Here are the top 16 website metrics you need to be tracking if you want to grow your business :

    1. Pageviews

    A pageview is the number of times a web page has been viewed. 

    Many pageviews can indicate a successful search engine optimisation (SEO) or marketing campaign — it can be used to show positive results for these initiatives.

    It can also help you determine various issues on individual pages. For instance, performance issues or poor website structure can cause visitors to get lost or confused while navigating your website.

    Screenshot example of the Matomo dashboard

    2. Average time on page

    Average time on a page is simply the time visitors spend on a specific page (not the entire website) ; tracking users’ time on various pages throughout your website can give you insights that can help you improve certain pages.

    If you get tons of traffic to a particular page, but the average time a visitor stays on that page is minimal, the content may need some work.

    Tracking this data can help determine if your website is engaging for your visitors or if you need to modify certain aspects to increase your visitors’ stay. Increasing the average time on the page will help boost your conversions and search engine rankings.

    3. Actions per visit

    Actions per visit is a key metric that tracks the average number of actions a visitor takes every time they visit your website. This data can help you track your audience engagement and the effectiveness of your content across your entire website.

    An action is any activity performed by your visitors on your website like :

    • Outlinks
    • Downloads
    • Page views
    • Internal site searches

    The higher your actions per visit, the more engaging your audience finds your website content. A side effect of increased actions is staying longer on the site and more likely to convert to your email list as a subscriber or pay for products as a customer.

    4. Bounce rate

    Like a bouncy ball, your website’s bounce rate measures how many users entered your site and “bounced” out without clicking on another page. This metric can be extremely helpful in determining user interest in your content. 

    You might be getting many visitors to your website, but if they “bounce” after visiting the first page they land on, that’s a great indicator that your content is not resonating with your audience.

    Remember, this metric should be taken with a grain of salt. 

    Your bounce rate may indicate that visitors are finding the exact information that they wanted and leaving pleased, so it’s not a black-and-white metric.

    For example, if you have a landing page with a high bounce rate, then that’s likely not a sign of a good user experience. But, if you have a knowledge base article and they just need to find some quick information, then it could be a good indicator.

    5. Conversions

    The first step in tracking conversions is defining what a conversion is for your website. 

    Do you want your audience to :

    • View a blog post
    • Purchase a product
    • Download an eBook
    • Sign up for a consultation call

    Determine what that conversion is and track how often users take that action on your website.

    This helps you understand if your marketing and content strategies are working toward your pre-defined conversion goal.

    Matomo track conversions.

    6. Conversion rate

    A conversion rate is the percentage of visits that triggered a conversion. Knowing this metric lets you plan, budget, and forecast future growth.

    For example, 5% of your website visitors take action and convert to customers. With this information, you can make better informed financial decisions regarding your marketing efforts on your website to help increase traffic and future conversions.

    While there are basic conversion rate benchmarks to strive toward, it ultimately depends on your goals and the specific conversions you decide to track that are best for your business. 

    That being said, Matomo has some best practices to help you optimise your conversion rates, no matter what conversion metric you are tracking.

    7. Exit rate

    While “bounce rate” and “exit rate” are similar, “exit rate” is the percentage of visits to a website that ended on a particular page.

    Knowing which pages have the highest percentage of visitors exiting your website gives you key information on the pages that may need to be improved.

    If you see that your “exit rate” is highest on pages before the checkout (or other CTA’s you have established), you will want to dive into what’s causing visitors to leave from that page. For example, maybe it’s the content, the copy or even a broken link.

    This is a great metric to help determine where you have breakdowns between you and your visitors. Improving your exit rate can help guide visitors through your website funnel more easily and boost your conversion rates. 

    Matomo track pageviews

    8. Top pages

    The top pages on your website are the pages that receive the most visits. Understanding what your top pages are can be crucial in planning and guiding your marketing strategies moving forward.

    Your top pages can help you determine the most engaging content for your audience. This can be extremely helpful in guiding your visitors to certain pages that other users find more valuable.

    It also helps you determine if you need to focus more attention on different parts of your website to increase user engagement in those areas.

    For example, maybe your most-viewed pages have less copy and more photos or videos. Understanding this lets you know that incorporating more media into other pages will boost future engagement.

    9. Traffic sources

    Your traffic sources are the channels that are driving visitors to your website. The four most common traffic sources are :

    • Direct Entry : Typing your website URL into their browser or visiting via a bookmark they saved
    • Websites/Referral : Clicking on a link to your site from another website
    • Search Engines : Using search engines (Google, Bing or Yahoo) to find your website
    • Campaigns : Visitors directed to your website through specific marketing campaigns, such as email newsletters, Google Ads, promotional links, etc.
    • Social Networks : Visitors accessing your website by clicking on links shared on social media platforms like Facebook, X (Twitter), LinkedIn, etc.

    Understanding where your visitors are coming from can help you focus your marketing efforts on the traffic sources with the highest conversion rates. 

    Suppose your email marketing campaign isn’t driving any traffic to your website, but your ad campaign is responsible for over 25% of your conversions. In that case, you might consider doubling your advertising efforts.

    10. Form average time spent

    Forms are a crucial part of your website’s marketing strategy. Forms can help you :

    • Learn more about your visitors
    • Gather feedback from your audience
    • Convert visitors into email subscribers
    • And more

    Form average time spent is the average amount of time a visitor spends on a specific form on your website. The time is calculated as the difference between the first interaction with a form field (for example, a field focus) and the last interaction with a form.

    Want to convert more visitors into leads ? Then, you need to understand your form analytics better. Learn more here.

    11. Play rate

    If you want to keep your audience engaged (and convert more visitors), you need to publish different types of media.

    But if your video or audio content isn’t performing well, then you’re wasting your time.

    That’s where play rate comes in. It’s calculated by analysing visitors who watched or listened to a specific media after they have visited a web page.

    With play rate, you can track any video, podcast, or audiobook plays.

    You can easily track it within Matomo’s Media Analytics. The best part ? This feature works out of the box, so you don’t need to configure it to start leveraging the analytics.

    Try Matomo for Free

    Get the web insights you need, without compromising data accuracy.

    No credit card required

    12. Returning visitors

    Returning visitors are users who visit your website more than once over a specific time.

    You will want to measure the number of returning visitors to your website, as this information can give you additional insights into your marketing strategies, company branding and content.

    It can also help you better understand your customer base, giving you a clearer sense of their top desires and pain points.

    13. Device type

    Device type tracks the different devices visitors use to visit your website. These could be :

    • Tablets
    • Mobile phones
    • Desktop computers

    Knowing what your visitors are using to access your website can help you improve the overall user experience.

    For example, if 80% of your visitors use mobile phones, you could think about optimising your web pages to format with mobile devices. 

    Screenshot of Matomo dashboard

    14. Top exit pages

    Top exit pages are the pages that a visitor leaves your website from the most.

    Each web page will have a specific exit rate percentage based on how many people leave the website on a particular page.

    This can be quite helpful in understanding how visitors interact with your website. It can also help you uncover and fix any issues with your website you may not be aware of.

    For instance, one of your product pages has the highest exit rate on your website. By looking into why that is, you discover that your “Add to Cart” button isn’t functioning correctly, and your visitors can’t buy that particular product, so they exit out of frustration.

    15. Marketing attribution

    Marketing attribution (multi-touch attribution) helps you see which touchpoints have the greatest impact on conversions.

    Within Matomo, revenue attribution involves assigning credit for revenue across multiple touchpoints that contribute to a conversion.

    Matomo’s multi-touch attribution models use different weighting factors, like linear or time decay, to allocate credit to each touchpoint based on its influence.

    Matomo’s multi-touch attribution reports provide insights into how revenue is distributed across different touchpoints, marketing channels, campaigns, and actions. These reports allow you to analyse the contribution of each touchpoint to revenue generation and identify the most influential interactions in the customer journey.

    Try Matomo for Free

    Get the web insights you need, without compromising data accuracy.

    No credit card required

    16. Event tracking

    Every website has multiple actions a user can perform called “events”. These could be downloading a template, submitting contact information, signing up for a newsletter or clicking a link.

    Tracking events can give you additional context into what your visitors are interested in or don’t care about. This allows you to target them better through those events, potentially creating new, unique conversions and boosting the growth of your business.

    It can also lead to discovering potential issues within your website if you notice visitors aren’t taking action on certain CTAs, such as broken links or lack of content on certain pages. By uncovering these issues, you can quickly fix them to increase your conversions.

    Matomo track events

    Start tracking your website metrics with Matomo today

    There’s much to consider when creating and running your website, such as the design, copy and flow. 

    While these are necessary, tracking your website’s data is one of the most important aspects of running a site. It’s crucial in helping you optimise your site’s performance and create a great experience for your visitors.

    Every interaction a visitor has on your site is unique and leaves valuable clues you can use to improve all aspects of your site experience. 

    Understanding what your visitors like, what website performance issues they’re running into and how they interact across your website is crucial to improving your marketing and sales efforts.

    While tracking this much data can feel overwhelming, having all your key metrics in one place and broken down into easy-to-understand benchmarks can help alleviate the stress and headache of data tracking. 

    That’s where a web analytics platform like Matomo comes in.

    With Matomo, you can easily track, store and analyse every piece of data on your website automatically to improve your site performance and user experience and drive conversions. 

    With Matomo, you can take back control with a platform that gives you 100% data ownership.

    Used on over 1 million websites in over 190 countries, Matomo gives you :

    • Accurate data (no data sampling)
    • Privacy-friendly and GDPR-compliant analytics
    • Open-source access to create a custom solution for you

    Try Matomo for free for 21 days now. No credit card required.