Skip to content

Commit 709272d

Browse files
committed
Remove debug code from enrichment A
1 parent 44df8ca commit 709272d

File tree

1 file changed

+0
-29
lines changed

1 file changed

+0
-29
lines changed

enrichment/A_file-system-operations/file-system-operations.ipynb

-29
Original file line numberDiff line numberDiff line change
@@ -28,35 +28,6 @@
2828
"The `music` directory contains 3 sub directories with a bunch of songs randomly collected in them, with no information on artist, album or song title. However we suspect that this information may be encoded in the files themselves as [ID3 metadata](https://en.wikipedia.org/wiki/ID3)."
2929
]
3030
},
31-
{
32-
"cell_type": "code",
33-
"execution_count": null,
34-
"metadata": {},
35-
"outputs": [],
36-
"source": [
37-
"from pathlib import Path\n",
38-
"import random\n",
39-
"\n",
40-
"music_dir = Path('music')\n",
41-
"songs = music_dir.glob(\"*.mp3\")\n",
42-
"\n",
43-
"songs_1 = (music_dir / 'songs_001')\n",
44-
"songs_2 = (music_dir / 'songs_002')\n",
45-
"songs_3 = (music_dir / 'songs_003')\n",
46-
"\n",
47-
"out_dirs = [songs_1, songs_2, songs_3]\n",
48-
"for out_dir in out_dirs:\n",
49-
" out_dir.mkdir(exist_ok=True)\n",
50-
"\n",
51-
"for song in songs:\n",
52-
" out_dir = random.choice(out_dirs)\n",
53-
" song.rename(out_dir / song.name)\n",
54-
"\n",
55-
"for out_dir in out_dirs:\n",
56-
" for i, file in enumerate(out_dir.iterdir()):\n",
57-
" file.rename(out_dir / f'song_{i:03}.mp3')"
58-
]
59-
},
6031
{
6132
"cell_type": "markdown",
6233
"metadata": {},

0 commit comments

Comments
 (0)