
Recherche avancée
Médias (3)
-
The Slip - Artworks
26 septembre 2011, par
Mis à jour : Septembre 2011
Langue : English
Type : Texte
-
Podcasting Legal guide
16 mai 2011, par
Mis à jour : Mai 2011
Langue : English
Type : Texte
-
Creativecommons informational flyer
16 mai 2011, par
Mis à jour : Juillet 2013
Langue : English
Type : Texte
Autres articles (93)
-
MediaSPIP 0.1 Beta version
25 avril 2011, parMediaSPIP 0.1 beta is the first version of MediaSPIP proclaimed as "usable".
The zip file provided here only contains the sources of MediaSPIP in its standalone version.
To get a working installation, you must manually install all-software dependencies on the server.
If you want to use this archive for an installation in "farm mode", you will also need to proceed to other manual (...) -
HTML5 audio and video support
13 avril 2011, parMediaSPIP uses HTML5 video and audio tags to play multimedia files, taking advantage of the latest W3C innovations supported by modern browsers.
The MediaSPIP player used has been created specifically for MediaSPIP and can be easily adapted to fit in with a specific theme.
For older browsers the Flowplayer flash fallback is used.
MediaSPIP allows for media playback on major mobile platforms with the above (...) -
ANNEXE : Les plugins utilisés spécifiquement pour la ferme
5 mars 2010, parLe site central/maître de la ferme a besoin d’utiliser plusieurs plugins supplémentaires vis à vis des canaux pour son bon fonctionnement. le plugin Gestion de la mutualisation ; le plugin inscription3 pour gérer les inscriptions et les demandes de création d’instance de mutualisation dès l’inscription des utilisateurs ; le plugin verifier qui fournit une API de vérification des champs (utilisé par inscription3) ; le plugin champs extras v2 nécessité par inscription3 (...)
Sur d’autres sites (8794)
-
Saving mp4 files into csv for training the data
4 février 2021, par KSpI am very new to the computer vision field and I am trying to train my model and as a start of the work, I used a label encoder to label my videos for events I am using. Here I have two events which are accident and no accident.


Folder Structure for the images :


Colab_Notebooks
- accident(all the .jpg frames are here)
- nonaccident(all the .jpg frames are here)



So my data.csv file looks like this and code given below.


data.csv 
image_path,target
/content/drive/MyDrive/Colab_Notebooks/accident/accident_0000638.jpg,0.0
/content/drive/MyDrive/Colab_Notebooks/nonaccident/nonaccident_0002143.jpg,1.0
/content/drive/MyDrive/Colab_Notebooks/accident/accident_0000372.jpg,0.0
/content/drive/MyDrive/Colab_Notebooks/accident/accident_0000419.jpg,0.0
/content/drive/MyDrive/Colab_Notebooks/nonaccident/nonaccident_0001675.jpg,1.0
/content/drive/MyDrive/Colab_Notebooks/accident/accident_0000307.jpg,0.0
/content/drive/MyDrive/Colab_Notebooks/accident/accident_00001099.jpg,0.0
/content/drive/MyDrive/Colab_Notebooks/accident/accident_0000940.jpg,0.0
/content/drive/MyDrive/Colab_Notebooks/accident/accident_0000892.jpg,0.0
/content/drive/MyDrive/Colab_Notebooks/accident/accident_0000805.jpg,0.0
/content/drive/MyDrive/Colab_Notebooks/accident/accident_0000232.jpg,0.0
/content/drive/MyDrive/Colab_Notebooks/accident/accident_0000255.jpg,0.0
/content/drive/MyDrive/Colab_Notebooks/accident/accident_0000840.jpg,0.0
/content/drive/MyDrive/Colab_Notebooks/accident/accident_0000974.jpg,0.0



The code i used for generating data.csv is as shown below :


all_paths = os.listdir('/content/drive/MyDrive/Colab_Notebooks/')

folder_paths = [x for x in all_paths if os.path.isdir('/content/drive/MyDrive/Colab_Notebooks/' + x )]

print(f"Folder paths : {folder_paths}")
print (f"Number of folders: {len(folder_paths)}")
create_labels = ['accident','nonaccident']

data = pd.DataFrame()

image_formats = ['jpg']
labels = []
counter = 0
for i, folder_path in tqdm(enumerate(folder_paths), total = len(folder_paths)):
 if folder_path not in create_labels:
 continue
 image_paths = os.listdir('/content/drive/MyDrive/Colab_Notebooks/' + folder_path)
 label = folder_path

 for image_path in image_paths:
 if image_path.split('.')[-1] in image_formats:
 data.loc[counter,'image_path'] = f"/content/drive/MyDrive/Colab_Notebooks/{folder_path}/{image_path}"
 labels.append(label)
 counter += 1
labels = np.array(labels)
# one-hot encode the labels
lb = LabelBinarizer()
labels = lb.fit_transform(labels)

#print(labels)

# save as CSV file
data.to_csv('/content/drive/MyDrive/Colab_Notebooks/data.csv', index=False)

# pickle the binarized labels
print('Saving the binarized labels as pickled file')
joblib.dump(lb, '/content/drive/MyDrive/Colab_Notebooks/lb.pkl')

print(data.head(5))



I was able to do this fine because the dataset you see on top is frames which are jpg images. But I would like to do the same for videos.


Colab_Notebooks
- accident(all the .mp4 clips are here)
- nonaccident(all the .mp4 clips are here)

Expected output:
/content/drive/MyDrive/Colab_Notebooks/accident/accident_0000638.mp4,0.0
/content/drive/MyDrive/Colab_Notebooks/nonaccident/nonaccident_0002143.mp4,1.0
/content/drive/MyDrive/Colab_Notebooks/accident/accident_0000372.mp4,0.0
/content/drive/MyDrive/Colab_Notebooks/accident/accident_0000419.mp4,0.0
/content/drive/MyDrive/Colab_Notebooks/nonaccident/nonaccident_0001675.mp4,1.0
/content/drive/MyDrive/Colab_Notebooks/accident/accident_0000307.mp4,0.0



Could someone tell me how do I modify the code to read the video clips instead of images ?


-
Revision bbffaf627b : Merge "General vp9_encodeframe.c cleanup."
7 avril 2014, par Dmitry KovalevChanged Paths :
Modify /vp9/encoder/vp9_encodeframe.c
Merge "General vp9_encodeframe.c cleanup." -
Revision 924dc81e74 : Merge "General cleanup in vp9_encodeframe.c."
10 mars 2014, par Dmitry KovalevChanged Paths :
Modify /vp9/encoder/vp9_encodeframe.c
Merge "General cleanup in vp9_encodeframe.c."