import{s as Ae,n as Me,o as De}from"../chunks/scheduler.35aab934.js";import{S as Ee,i as Se,e as o,s as a,c as p,h as We,a as l,d as i,b as s,f as ze,g as m,j as r,k as He,l as Ue,m as n,n as c,t as u,o as f,p as g}from"../chunks/index.de17b971.js";import{C as Re}from"../chunks/CopyLLMTxtMenu.48bc5cc2.js";import{H as U,E as je}from"../chunks/MermaidChart.svelte_svelte_type_style_lang.8fdece89.js";function Be(he){let d,B,R,F,h,G,v,N,y,ve=`Welcome to the Video and Video Processing unit. Maybe you have realized that in our course content so far, we have mainly focused on standard, static 2D images.
Of course, the real world of Computer Vision has a lot more to offer. Videos are definitely one of the most used mediums in our world due to applications like Social Media, broadcasts, or surveillance cameras.`,O,$,ye="Given their importance in our society and research, we also want to talk about them here in our course. In this introduction chapter, you will learn some very basic theory behind videos before going on to have a closer look at video processing.",Y,x,K,b,$e="An image is a binary, two-dimensional (2D) representation of visual data. A video is a multimedia format that sequentially displays these frames or images.",J,C,xe=`Technically speaking, the frames are separate pictures. As a result, storing and playing these frames sequentially at a conventional speed results in the creation of a video, thus giving the illusion of motion (just like a flipbook).
It is a popular and widely used medium for communicating information, entertainment, and conversation. Videos and photos are obtained via image-acquisition equipment such as video cameras, smartphones, and so on.`,Q,w,X,_,be=`<li><p><strong>Resolution:</strong>
The resolution of a video refers to the number of pixels in each frame or we can also refer to it as the size of each frame in the video. It doesn’t need to be a standard size, but there are common sizes for video. Common video resolutions include HD (1280x720 pixels), Full HD (1920x1080 pixels), Ultra HD or 4K (3840x2160 pixels), and so on.
When a video is said to have a resolution of 1920x1080 pixels, it essentially means the video has a width of 1920 pixels and a height of 1080 pixels.
Higher resolution videos have more detail but also require more storage space and processing power.</p></li> <li><p><strong>Frame Rate:</strong>
A video is composed of multiple separate frames, or images. In order to give the impression of motion, these frames are displayed quickly one after the other.
The number of frames displayed per second is called the “frame rate.” Common frame rates include 24, 30, and 60 frames per second (fps) or hertz (general unit for frequency). Higher frame rates result in smoother motion.</p></li> <li><p><strong>Bitrate:</strong>
The quantity of data needed to describe audio and video is called bitrate. Better quality is achieved at higher bitrates, but streaming requires more storage and bandwidth.</p></li>`,Z,T,Ce="Bitrates for videos are commonly expressed in megabytes per second (mbps) or kilobytes per second (kbps).",ee,q,we=`<li><strong>Codecs:</strong>
Codecs, short for “compressor-decompressor” are software or hardware components that compress and decompress digital media to reduce the size of media files, making them more manageable for storage and transmission while maintaining an acceptable level of quality.
There are two main types of codecs; “lossless codecs” and “lossy codecs”. Lossless codecs are designed to compress data without any loss of quality, while lossy codecs are more designed to compress by removing some of the data resulting in a loss of quality.</li>`,te,P,_e="In summary, a video is a dynamic multimedia format that combines a series of individual frames, audio, and often additional metadata. It is used in a wide range of applications and can be tailored for different purposes, whether for entertainment, education, communication, or analysis.",ie,V,ne,I,Te="In the research field of Computer Vision (CV) and Artificial Intelligence (AI), video processing involves automatically analyzing video data to understand and interpret both temporal and spatial features. Video data is simply a sequence of time-varying images, where the information is digitized both spatially and temporally. This allows us to perform detailed analysis and manipulation of the content within each frame of the video.",ae,L,qe="Video processing has become increasingly important in today’s technology-driven world, thanks to the rapid advancements in Deep Learning (DL) and AI. Traditionally, DL research has focused on images, speech, and text, but video data offers a unique and valuable opportunity for research due to its extensive size and complexity. With millions of videos uploaded daily on platforms like YouTube, video data has become a rich resource, driving AI research and enabling groundbreaking applications.",se,k,oe,z,Pe=`<li><p><strong>Surveillance Systems:</strong>
Video processing plays a critical role in public safety, crime prevention, and traffic monitoring. It enables the automated detection of suspicious activities, helps identify individuals, and enhances the efficiency of surveillance systems.<br/></p></li> <li><p><strong>Autonomous Driving:</strong>
In the realm of autonomous driving, video processing is essential for navigation, obstacle detection, and decision-making processes. It allows self-driving cars to understand their surroundings, recognize road signs, and react to changing environments, ensuring safe and efficient transportation.</p></li> <li><p><strong>Healthcare:</strong>
Video processing has significant applications in healthcare, including medical diagnostics, surgery, and patient monitoring. It helps analyze medical images, provides real-time feedback during surgical procedures, and continuously monitors patients to detect any abnormalities or emergencies.</p></li>`,le,H,re,A,Ve=`<li><p><strong>Computational Demands:</strong>
Real-time video analysis requires substantial processing power, which poses a significant challenge in developing and deploying efficient video processing systems. High-performance computing resources are essential to meet these demands.</p></li> <li><p><strong>Storage Requirements:</strong>
High-resolution videos generate large volumes of data, leading to storage challenges. Efficient data compression and management techniques are necessary to handle the vast amounts of video data.</p></li> <li><p><strong>Privacy and Ethical Concerns:</strong>
Video processing, especially in surveillance and healthcare, involves handling sensitive information. Ensuring privacy and addressing ethical concerns related to the misuse of video data are crucial considerations that must be carefully managed.</p></li>`,de,M,pe,D,Ie="Video processing is a dynamic and vital area within AI and CV, offering numerous applications and presenting unique challenges. Its importance in modern technology continues to grow, fueled by advancements in deep learning and the increasing availability of video data. In the following sections, we will dive deeper into deep learning for video processing. You’ll explore state-of-the-art models including 3D CNNs and Transformers.",me,E,Le="Additionally, we’ll cover various tasks such as object tracking, action recognition, video stabilization, captioning, summarization, and background subtraction. These topics will provide you with a comprehensive understanding of how deep learning models are applied to different video processing challenges and applications.",ce,S,ke="Let’s go! 🤓",ue,W,fe,j,ge;return h=new Re({props:{containerStyle:"float: right; margin-left: 10px; display: inline-flex; position: relative; z-index: 10;"}}),v=new U({props:{title:"Introduction",local:"introduction",headingTag:"h1"}}),x=new U({props:{title:"What is a Video?",local:"what-is-a-video",headingTag:"h2"}}),w=new U({props:{title:"Aspects of a Video",local:"aspects-of-a-video",headingTag:"h3"}}),V=new U({props:{title:"What is Video Processing?",local:"what-is-video-processing",headingTag:"h2"}}),k=new U({props:{title:"Applications of Video Processing",local:"applications-of-video-processing",headingTag:"h3"}}),H=new U({props:{title:"Challenges in Video Processing",local:"challenges-in-video-processing",headingTag:"h3"}}),M=new U({props:{title:"Conclusion",local:"conclusion",headingTag:"h2"}}),W=new je({props:{source:"https://github.com/huggingface/computer-vision-course/blob/main/chapters/en/unit7/video-processing/introduction-to-video.mdx"}}),{c(){d=o("meta"),B=a(),R=o("p"),F=a(),p(h.$$.fragment),G=a(),p(v.$$.fragment),N=a(),y=o("p"),y.textContent=ve,O=a(),$=o("p"),$.textContent=ye,Y=a(),p(x.$$.fragment),K=a(),b=o("p"),b.textContent=$e,J=a(),C=o("p"),C.textContent=xe,Q=a(),p(w.$$.fragment),X=a(),_=o("ul"),_.innerHTML=be,Z=a(),T=o("p"),T.textContent=Ce,ee=a(),q=o("ul"),q.innerHTML=we,te=a(),P=o("p"),P.textContent=_e,ie=a(),p(V.$$.fragment),ne=a(),I=o("p"),I.textContent=Te,ae=a(),L=o("p"),L.textContent=qe,se=a(),p(k.$$.fragment),oe=a(),z=o("ul"),z.innerHTML=Pe,le=a(),p(H.$$.fragment),re=a(),A=o("ul"),A.innerHTML=Ve,de=a(),p(M.$$.fragment),pe=a(),D=o("p"),D.textContent=Ie,me=a(),E=o("p"),E.textContent=Le,ce=a(),S=o("p"),S.textContent=ke,ue=a(),p(W.$$.fragment),fe=a(),j=o("p"),this.h()},l(e){const t=We("svelte-u9bgzb",document.head);d=l(t,"META",{name:!0,content:!0}),t.forEach(i),B=s(e),R=l(e,"P",{}),ze(R).forEach(i),F=s(e),m(h.$$.fragment,e),G=s(e),m(v.$$.fragment,e),N=s(e),y=l(e,"P",{"data-svelte-h":!0}),r(y)!=="svelte-1padjc6"&&(y.textContent=ve),O=s(e),$=l(e,"P",{"data-svelte-h":!0}),r($)!=="svelte-upvie1"&&($.textContent=ye),Y=s(e),m(x.$$.fragment,e),K=s(e),b=l(e,"P",{"data-svelte-h":!0}),r(b)!=="svelte-10q29za"&&(b.textContent=$e),J=s(e),C=l(e,"P",{"data-svelte-h":!0}),r(C)!=="svelte-9w7mfy"&&(C.textContent=xe),Q=s(e),m(w.$$.fragment,e),X=s(e),_=l(e,"UL",{"data-svelte-h":!0}),r(_)!=="svelte-7hg889"&&(_.innerHTML=be),Z=s(e),T=l(e,"P",{"data-svelte-h":!0}),r(T)!=="svelte-v1a01l"&&(T.textContent=Ce),ee=s(e),q=l(e,"UL",{"data-svelte-h":!0}),r(q)!=="svelte-16y68c2"&&(q.innerHTML=we),te=s(e),P=l(e,"P",{"data-svelte-h":!0}),r(P)!=="svelte-zqye5x"&&(P.textContent=_e),ie=s(e),m(V.$$.fragment,e),ne=s(e),I=l(e,"P",{"data-svelte-h":!0}),r(I)!=="svelte-1qty5it"&&(I.textContent=Te),ae=s(e),L=l(e,"P",{"data-svelte-h":!0}),r(L)!=="svelte-1pxq8ue"&&(L.textContent=qe),se=s(e),m(k.$$.fragment,e),oe=s(e),z=l(e,"UL",{"data-svelte-h":!0}),r(z)!=="svelte-1dao97m"&&(z.innerHTML=Pe),le=s(e),m(H.$$.fragment,e),re=s(e),A=l(e,"UL",{"data-svelte-h":!0}),r(A)!=="svelte-1y8rezn"&&(A.innerHTML=Ve),de=s(e),m(M.$$.fragment,e),pe=s(e),D=l(e,"P",{"data-svelte-h":!0}),r(D)!=="svelte-181o49r"&&(D.textContent=Ie),me=s(e),E=l(e,"P",{"data-svelte-h":!0}),r(E)!=="svelte-q5676r"&&(E.textContent=Le),ce=s(e),S=l(e,"P",{"data-svelte-h":!0}),r(S)!=="svelte-toty5d"&&(S.textContent=ke),ue=s(e),m(W.$$.fragment,e),fe=s(e),j=l(e,"P",{}),ze(j).forEach(i),this.h()},h(){He(d,"name","hf:doc:metadata"),He(d,"content",Fe)},m(e,t){Ue(document.head,d),n(e,B,t),n(e,R,t),n(e,F,t),c(h,e,t),n(e,G,t),c(v,e,t),n(e,N,t),n(e,y,t),n(e,O,t),n(e,$,t),n(e,Y,t),c(x,e,t),n(e,K,t),n(e,b,t),n(e,J,t),n(e,C,t),n(e,Q,t),c(w,e,t),n(e,X,t),n(e,_,t),n(e,Z,t),n(e,T,t),n(e,ee,t),n(e,q,t),n(e,te,t),n(e,P,t),n(e,ie,t),c(V,e,t),n(e,ne,t),n(e,I,t),n(e,ae,t),n(e,L,t),n(e,se,t),c(k,e,t),n(e,oe,t),n(e,z,t),n(e,le,t),c(H,e,t),n(e,re,t),n(e,A,t),n(e,de,t),c(M,e,t),n(e,pe,t),n(e,D,t),n(e,me,t),n(e,E,t),n(e,ce,t),n(e,S,t),n(e,ue,t),c(W,e,t),n(e,fe,t),n(e,j,t),ge=!0},p:Me,i(e){ge||(u(h.$$.fragment,e),u(v.$$.fragment,e),u(x.$$.fragment,e),u(w.$$.fragment,e),u(V.$$.fragment,e),u(k.$$.fragment,e),u(H.$$.fragment,e),u(M.$$.fragment,e),u(W.$$.fragment,e),ge=!0)},o(e){f(h.$$.fragment,e),f(v.$$.fragment,e),f(x.$$.fragment,e),f(w.$$.fragment,e),f(V.$$.fragment,e),f(k.$$.fragment,e),f(H.$$.fragment,e),f(M.$$.fragment,e),f(W.$$.fragment,e),ge=!1},d(e){e&&(i(B),i(R),i(F),i(G),i(N),i(y),i(O),i($),i(Y),i(K),i(b),i(J),i(C),i(Q),i(X),i(_),i(Z),i(T),i(ee),i(q),i(te),i(P),i(ie),i(ne),i(I),i(ae),i(L),i(se),i(oe),i(z),i(le),i(re),i(A),i(de),i(pe),i(D),i(me),i(E),i(ce),i(S),i(ue),i(fe),i(j)),i(d),g(h,e),g(v,e),g(x,e),g(w,e),g(V,e),g(k,e),g(H,e),g(M,e),g(W,e)}}}const Fe='{"title":"Introduction","local":"introduction","sections":[{"title":"What is a Video?","local":"what-is-a-video","sections":[{"title":"Aspects of a Video","local":"aspects-of-a-video","sections":[],"depth":3}],"depth":2},{"title":"What is Video Processing?","local":"what-is-video-processing","sections":[{"title":"Applications of Video Processing","local":"applications-of-video-processing","sections":[],"depth":3},{"title":"Challenges in Video Processing","local":"challenges-in-video-processing","sections":[],"depth":3}],"depth":2},{"title":"Conclusion","local":"conclusion","sections":[],"depth":2}],"depth":1}';function Ge(he){return De(()=>{new URLSearchParams(window.location.search).get("fw")}),[]}class Je extends Ee{constructor(d){super(),Se(this,d,Ge,Be,Ae,{})}}export{Je as component};
