Skip to content

Commit

Permalink
Merge pull request #88 from HE-Arc/add_demo_file
Browse files Browse the repository at this point in the history
add demo file
  • Loading branch information
maelys-buhler authored Dec 14, 2023
2 parents f28e128 + 962ff76 commit 4de27a5
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 0 deletions.
4 changes: 4 additions & 0 deletions database/seeders/SongSeeder.php
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,11 @@ class SongSeeder extends Seeder
public function run(): void
{
LazyCollection::make(function () {
$DEMO = false;
$file_path = 'seeds/playlist_2010to2022_improved.csv';
if ($DEMO) {
$file_path = 'seeds/playlist_2010to2022_demo.csv';
}
$handle = fopen(public_path($file_path), 'r');

while (($line = fgetcsv($handle, 4096)) !== false) {
Expand Down
11 changes: 11 additions & 0 deletions public/seeds/playlist_2010to2022_demo.csv
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
playlist_url;year;track_id;track_name;track_popularity;album;artist_id;artist_name;artist_genres;artist_popularity;danceability;energy;key;loudness;mode;speechiness;acousticness;instrumentalness;liveness;valence;tempo;duration_ms;time_signature
;2008;2EvwLVrnYbCZEG6Kx5DCRy;Piece of Me;66;Blackout;26dSoYclwsYLMAKD3tpOr4;Britney Spears;['dance pop', 'pop'];78;0.769;0.638;11;-5.054;1;0.216;0.0902;0;0.0857;0.782;115.007;212107;4
https://open.spotify.com/playlist/37i9dQZF1DXc6IFF23C9jj;2010;2GYHyAoLWpkxLVa4oYTVko;Alors on danse - Radio Edit;80;Cheese;5j4HeCoUlzhfWtjAfM1acR;Stromae;['belgian pop', 'g-house'];69;0.791;0.59;1;-9.206;0;0.0793;0.0994;0.00203;0.065;0.714;119.951;206067;4
https://open.spotify.com/playlist/37i9dQZF1DXcagnSNtrGuJ;2011;4r6eNCsrZnQWJzzvFh4nlg;Firework;73;Teenage Dream;6jJ0s89eD6GaHleKKya26X;Katy Perry;['pop'];82;0.638;0.832;8;-5.039;1;0.049;0.141;0;0.113;0.648;124.071;227893;4
https://open.spotify.com/playlist/37i9dQZF1DX0yEZaMOXna3;2012;03UrZgTINDqvnUMbbIMhql;Gangnam Style;76;Gangnam Style;2dd5mrQZvg6SmahdgVKDzh;PSY;['k-rap', 'korean old school hip hop'];62;0.727;0.937;11;-2.871;0;0.286;0.0042;0;0.091;0.749;132.067;219493;4
https://open.spotify.com/playlist/37i9dQZF1DX3Sp0P28SIer;2013;2E43WFS4rRc09za2r2GmZl;My Songs Know What You Did In The Dark (Light Em Up);77;Save Rock And Roll;4UXqAaa6dQYAk18Lv7PEgX;Fall Out Boy;['emo', 'modern rock', 'pop', 'pop punk', 'rock'];78;0.558;0.924;9;-4.341;0;0.064;0.0271;0.00000332;0.537;0.567;151.99;186827;4
https://open.spotify.com/playlist/37i9dQZF1DX9ukdrXQLJGZ;2015;62PaSfnXSMyLshYJrlTuL3;Hello;75;25;4dpARuHxo51G3z768sgnrY;Adele;['british soul', 'pop', 'pop soul', 'uk pop'];83;0.578;0.43;5;-6.134;0;0.0305;0.33;0;0.0854;0.288;78.991;295502;4
https://open.spotify.com/playlist/37i9dQZF1DWTE7dVUebpUW;2017;7qiZfU4dY1lWllzX7mPBI3;Shape of You;89;A (Deluxe);6eUKZXaKkcviH0Ku9w2n3V;Ed Sheeran;['pop', 'singer-songwriter pop', 'uk pop'];87;0.825;0.652;1;-3.183;0;0.0802;0.581;0;0.0931;0.931;95.977;233713;4
https://open.spotify.com/playlist/37i9dQZF1DWVRSukIED0e9;2019;43zdsphuZLzwA9k4DJhU0I;when the party's over;85;WHEN WE ALL FALL ASLEEP, WHERE DO WE GO?;6qqNVTkY8uBg9cP3Jd7DAH;Billie Eilish;['art pop', 'electropop', 'pop'];88;0.367;0.111;4;-14.084;1;0.0972;0.978;0.0000397;0.0897;0.198;82.642;196077;4
https://open.spotify.com/playlist/56r5qRUv3jSxADdmBkhcz7;2022;29d0nY7TzCoi22XBqDQkiP;Running Up That Hill (A Deal With God) - 2018 Remaster;28;Hounds of Love (2018 Remaster);1aSxMhuvixZ8h9dK9jIDwL;Kate Bush;['art pop', 'art rock', 'baroque pop', 'new wave pop', 'permanent wave', 'piano rock', 'singer-songwriter'];67;0.625;0.533;10;-11.903;0;0.0596;0.659;0.00266;0.0546;0.139;108.296;300840;4
https://open.spotify.com/playlist/56r5qRUv3jSxADdmBkhcz7;2022;1r9xUipOqoNwggBpENDsvJ;Enemy (with JID) - from the series Arcane League of Legends;81;Enemy (with JID) [from the series Arcane League of Legends];53XhwfbYqKCa1cC15pYq2q;Imagine Dragons;['modern rock', 'pop', 'rock'];86;0.728;0.783;11;-4.424;0;0.266;0.237;0;0.434;0.555;77.011;173381;4

0 comments on commit 4de27a5

Please sign in to comment.