# Convert label to cue sheet, and cue sheet to label

**URL:** <https://forum.audacityteam.org/t/convert-label-to-cue-sheet-and-cue-sheet-to-label/19925>\
**Category:** General Audio Programming\
**Created:** [June 27, 2011, 5:28pm UTC](https://forum.audacityteam.org/t/convert-label-to-cue-sheet-and-cue-sheet-to-label/19925 "2011-06-27T17:28:21Z")\
**Posts on this page:** 20\
**Page:** 1

<div class="post-metadata">

**Author:** ![grimblefritz](https://forum.audacityteam.org/letter_avatar_proxy/v4/letter/g/c68b51/32.png) [@grimblefritz](https://forum.audacityteam.org/u/grimblefritz)\
**Post date:** [June 27, 2011, 5:28pm UTC](https://forum.audacityteam.org/t/convert-label-to-cue-sheet-and-cue-sheet-to-label/19925/1 "2011-06-27T17:28:21Z")

</div>

I have created a web tool to:

– convert labels to cue sheets  
– convert cue sheets to labels

See the Wiki at [http://wiki.audacityteam.org/wiki/Cue\_sheets#webtool](http://wiki.audacityteam.org/wiki/Cue_sheets#webtool)

---

<div class="post-metadata">

**Author:** ![steve](https://forum.audacityteam.org/letter_avatar_proxy/v4/letter/s/f19dbf/32.png) [@steve](https://forum.audacityteam.org/u/steve)\
**Post date:** [June 27, 2011, 8:43pm UTC](https://forum.audacityteam.org/t/convert-label-to-cue-sheet-and-cue-sheet-to-label/19925/2 "2011-06-27T20:43:19Z")

</div>

Nice work grimblefritz.  
It may be worth noting somewhere in your documentation that for Audacity 1.3 label tracks, if region labels are used, then only the start point of the region label is used for generating the cue sheet.

---

<div class="post-metadata">

**Author:** ![Gale\_Andrews](https://forum.audacityteam.org/letter_avatar_proxy/v4/letter/g/e0b2c6/32.png) [@Gale\_Andrews](https://forum.audacityteam.org/u/Gale_Andrews)\
**Post date:** [September 6, 2011, 4:12pm UTC](https://forum.audacityteam.org/t/convert-label-to-cue-sheet-and-cue-sheet-to-label/19925/3 "2011-09-06T16:12:07Z")

</div>

Apologies if I am being stupid, but if I paste contents of a simple Audacity 1.3.13 Beta labels file thus:

```plaintext
2.232558	2.232558	a
10.534884	10.534884	b

```

into [http://grimblefritz.com/audacity/lbl2cue.php](http://grimblefritz.com/audacity/lbl2cue.php) (“Convert Audacity labels to CUE sheet”) then press “Convert”, there is no output or error message in the screen that appears.

Tested in Firefox 5 and IE8 on Win XP.

For a possible enhancement, how about letting users select a text file from the computer for conversion?  
  
  
  
Gale

---

<div class="post-metadata">

**Author:** ![steve](https://forum.audacityteam.org/letter_avatar_proxy/v4/letter/s/f19dbf/32.png) [@steve](https://forum.audacityteam.org/u/steve)\
**Post date:** [September 6, 2011, 5:17pm UTC](https://forum.audacityteam.org/t/convert-label-to-cue-sheet-and-cue-sheet-to-label/19925/4 "2011-09-06T17:17:46Z")

</div>

Unfortunately it appears to be no longer functional.

---

<div class="post-metadata">

**Author:** ![grimblefritz](https://forum.audacityteam.org/letter_avatar_proxy/v4/letter/g/c68b51/32.png) [@grimblefritz](https://forum.audacityteam.org/u/grimblefritz)\
**Post date:** [September 18, 2011, 5:42am UTC](https://forum.audacityteam.org/t/convert-label-to-cue-sheet-and-cue-sheet-to-label/19925/5 "2011-09-18T05:42:27Z")

</div>

Sorry, everyone. I took on a project that my old web host couldn’t handle, so I had to change hosting companies. In moving things over, I missed a configuration setting in these tools.

Everything should be working again.

I had considered adding file upload, but there haven’t been that many users. It’s on the list, but to be honest it’s not high on the list.

---

<div class="post-metadata">

**Author:** ![grimblefritz](https://forum.audacityteam.org/letter_avatar_proxy/v4/letter/g/c68b51/32.png) [@grimblefritz](https://forum.audacityteam.org/u/grimblefritz)\
**Post date:** [September 18, 2011, 5:46am UTC](https://forum.audacityteam.org/t/convert-label-to-cue-sheet-and-cue-sheet-to-label/19925/6 "2011-09-18T05:46:15Z")

</div>

Also, I thought I had subscribed to this topic, but that’s what I get for doing my own thinking!

NOW I’m subscribed to it, so I should be quicker getting back to folks on comments here.

---

<div class="post-metadata">

**Author:** ![Gale\_Andrews](https://forum.audacityteam.org/letter_avatar_proxy/v4/letter/g/e0b2c6/32.png) [@Gale\_Andrews](https://forum.audacityteam.org/u/Gale_Andrews)\
**Post date:** [September 18, 2011, 8:01pm UTC](https://forum.audacityteam.org/t/convert-label-to-cue-sheet-and-cue-sheet-to-label/19925/7 "2011-09-18T20:01:48Z")

</div>

Thanks for fixing it.  
  
  
Gale

---

<div class="post-metadata">

**Author:** ![milesvs](https://forum.audacityteam.org/user_avatar/forum.audacityteam.org/milesvs/32/31316_2.png) [@milesvs](https://forum.audacityteam.org/u/milesvs)\
**Post date:** [August 14, 2021, 7:22pm UTC](https://forum.audacityteam.org/t/convert-label-to-cue-sheet-and-cue-sheet-to-label/19925/8 "2021-08-14T19:22:03Z")

</div>

Came upon this tool, very helpful for my situation!  
I’m creating DJ mixes (with Pioneer Rekordbox 6), to master the recording I edit in in Audacity.

Unfortunately there seems to be a problem when there are also hours in the cue sheet.

An example cue sheet I get:

```plaintext
REM DATE 2021-08-14 04:27 PM
REM RECORDED_BY "rekordbox-dj"
TITLE "My Mix"
PERFORMER "DJ Me"
FILE "My Mixfile.wav" WAVE
	TRACK 01 AUDIO
		TITLE "Song One"
		PERFORMER "Artist One"
		FILE "c:/path/to/artist1-song1.mp3" WAVE
		INDEX 01 00:00:00:00
	TRACK 02 AUDIO
		TITLE "Song Two"
		PERFORMER "Artist Two"
		FILE "c:/path/to/artist2-song2.mp3" WAVE		
		INDEX 01 00:22:41:00
	TRACK 03 AUDIO
		TITLE "Song Three"
		PERFORMER "Artist Three"
		FILE "c:/path/to/artist3-song3.mp3" WAVE
		INDEX 01 01:08:15

```

I [read](http://grimblefritz.com/audacity/) the order of the tags should be: FILE, TITLE and INDEX  
So I changed the cuesheet to:

```plaintext
REM DATE 2021-08-14 04:27 PM
REM RECORDED_BY "rekordbox-dj"
TITLE "My Mix"
PERFORMER "DJ Me"
FILE "My Mixfile.wav" WAVE
	TRACK 01 AUDIO
		FILE "c:/path/to/artist1-song1.mp3" WAVE
		TITLE "Song One"
		PERFORMER "Artist One"
		INDEX 01 00:00:00:00
	TRACK 02 AUDIO
		FILE "c:/path/to/artist2-song2.mp3" WAVE
		TITLE "Song Two"
		PERFORMER "Artist Two"
		INDEX 01 00:22:41:00
	TRACK 03 AUDIO
		FILE "c:/path/to/artist3-song3.mp3" WAVE
		TITLE "Song Three"
		PERFORMER "Artist Three"
		INDEX 01 01:08:15

```

When I convert this in [the tool](http://grimblefritz.com/audacity/cue2lbl.php) I get:

```plaintext
0.000000	0.000000	Song One
22.546667	22.546667	Song Two
68.200000	68.200000	Song Three

```

Now look at Song Two: according to the result this starts at the 22nd SECOND. This should be the 22nd MINUTE though.  
When I remove the leading string “00:” from the cue sheet it does work correctly.

Can this be fixed?  
OR can I find the source PHP somewhere, so I can try to fix (and host) it myself?

---

<div class="post-metadata">

**Author:** ![steve](https://forum.audacityteam.org/letter_avatar_proxy/v4/letter/s/f19dbf/32.png) [@steve](https://forum.audacityteam.org/u/steve)\
**Post date:** [August 14, 2021, 8:16pm UTC](https://forum.audacityteam.org/t/convert-label-to-cue-sheet-and-cue-sheet-to-label/19925/9 "2021-08-14T20:16:31Z")

</div>

> [@](#):
>
> When I remove the leading string “00:” from the cue sheet it does work correctly.

According to this page: [Cue sheet (computing) - Wikipedia](https://en.wikipedia.org/wiki/Cue_sheet_%28computing%29) the time index should be written as  
mm:ss:ff (minute-second-frame) format.

---

<div class="post-metadata">

**Author:** ![milesvs](https://forum.audacityteam.org/user_avatar/forum.audacityteam.org/milesvs/32/31316_2.png) [@milesvs](https://forum.audacityteam.org/u/milesvs)\
**Post date:** [August 14, 2021, 9:19pm UTC](https://forum.audacityteam.org/t/convert-label-to-cue-sheet-and-cue-sheet-to-label/19925/10 "2021-08-14T21:19:53Z")

</div>

> [@](#):
>
> > [@](#):
> >
> > When I remove the leading string “00:” from the cue sheet it does work correctly.
> 
> According to this page: [Cue sheet (computing) - Wikipedia](https://en.wikipedia.org/wiki/Cue_sheet_%28computing%29) the time index should be written as  
> mm:ss:ff (minute-second-frame) format.

Thanks. Appears indeed Rekordbox doesn’t follow the standard ☹.  
Anyway, unfortunately the output of Rekordbox is hard to alter. (The code of) this tool is probably more within reach 🙂. If there is a source file of the converter I can rewrite it to a “Rekordbox Cuesheet to Audacity Label Converter” (credits included of course).

---

<div class="post-metadata">

**Author:** ![steve](https://forum.audacityteam.org/letter_avatar_proxy/v4/letter/s/f19dbf/32.png) [@steve](https://forum.audacityteam.org/u/steve)\
**Post date:** [August 14, 2021, 9:30pm UTC](https://forum.audacityteam.org/t/convert-label-to-cue-sheet-and-cue-sheet-to-label/19925/11 "2021-08-14T21:30:22Z")

</div>

> [@](#):
>
> (The code of) this tool is probably more within reach

or maybe not. The code is on grimblefritz’s website (not an Audacity website), but grimblefritz hasn’t logged in here since 2011.

---

<div class="post-metadata">

**Author:** ![grimblefritz](https://forum.audacityteam.org/letter_avatar_proxy/v4/letter/g/c68b51/32.png) [@grimblefritz](https://forum.audacityteam.org/u/grimblefritz)\
**Post date:** [August 14, 2021, 9:55pm UTC](https://forum.audacityteam.org/t/convert-label-to-cue-sheet-and-cue-sheet-to-label/19925/12 "2021-08-14T21:55:26Z")

</div>

At least, not as grimblefritz 🙂

---

<div class="post-metadata">

**Author:** ![grimblefritz](https://forum.audacityteam.org/letter_avatar_proxy/v4/letter/g/c68b51/32.png) [@grimblefritz](https://forum.audacityteam.org/u/grimblefritz)\
**Post date:** [August 14, 2021, 10:13pm UTC](https://forum.audacityteam.org/t/convert-label-to-cue-sheet-and-cue-sheet-to-label/19925/13 "2021-08-14T22:13:01Z")

</div>

So… I had to go look. This WAS over a decade ago and I couldn’t remember AT ALL what I did.

If I recall correctly, I had hundreds, maybe thousands, of audio files to process. And cue files saved me a TON of manual work.

I wrote the first go in awk. That got wrapped in bash with some options. And that got a PHP front end stuck on it.

And then, I finished my project that spawned lbl2cue & cue2lbl … and have never needed them again.

Who would like to take over this functional and yet horribly dysfunctional bit of code? I had (I call it “an episode”) in 2015 and subsequently I can’t remember details of stuff like this, and I struggle to absorb and grasp new stuff, so it needs to move on to someone with a brain that still functions correctly and has a need and the interest. Oh, and skills if you insist 🙂

---

<div class="post-metadata">

**Author:** ![steve](https://forum.audacityteam.org/letter_avatar_proxy/v4/letter/s/f19dbf/32.png) [@steve](https://forum.audacityteam.org/u/steve)\
**Post date:** [August 14, 2021, 11:33pm UTC](https://forum.audacityteam.org/t/convert-label-to-cue-sheet-and-cue-sheet-to-label/19925/14 "2021-08-14T23:33:12Z")

</div>

> [@](#):
>
> At least, not as grimblefritz 🙂

😲  
Hi there Grimblefritz. I guess the “subscribe to topic” works 😃

---

<div class="post-metadata">

**Author:** ![steve](https://forum.audacityteam.org/letter_avatar_proxy/v4/letter/s/f19dbf/32.png) [@steve](https://forum.audacityteam.org/u/steve)\
**Post date:** [August 14, 2021, 11:42pm UTC](https://forum.audacityteam.org/t/convert-label-to-cue-sheet-and-cue-sheet-to-label/19925/15 "2021-08-14T23:42:29Z")

</div>

> [@](#):
>
> I wrote the first go in awk. That got wrapped in bash with some options. And that got a PHP front end stuck on it.
> 
> And then, I finished my project that spawned lbl2cue & cue2lbl … and have never needed them again.

Was your tool based on these bash scripts: [Missing features - Audacity Support](https://wiki.audacityteam.org/wiki/Cue_sheets#Bash_script_to_create_cue_sheet_from_labels)

---

<div class="post-metadata">

**Author:** ![milesvs](https://forum.audacityteam.org/user_avatar/forum.audacityteam.org/milesvs/32/31316_2.png) [@milesvs](https://forum.audacityteam.org/u/milesvs)\
**Post date:** [August 15, 2021, 11:55am UTC](https://forum.audacityteam.org/t/convert-label-to-cue-sheet-and-cue-sheet-to-label/19925/16 "2021-08-15T11:55:25Z")

</div>

I also figured it was a very old topic and was also hoping the topic notification would do its magic. Glad it did! 😃

> [@](#):
>
> I wrote the first go in awk. That got wrapped in bash with some options. And that got a PHP front end stuck on it.

Sounds complicated! I assumed it would only be some PHP (and JS), but you apparently had a primary goal via shell…

> [@](#):
>
> Who would like to take over this functional and yet horribly dysfunctional bit of code? I had (I call it “an episode”) in 2015 and subsequently I can’t remember details of stuff like this, and I struggle to absorb and grasp new stuff, so it needs to move on to someone with a brain that still functions correctly and has a need and the interest. Oh, and skills if you insist 🙂

I’m afraid I don’t fit the bill. I can tweak existing PHP / JS (CSS/HTML) to my needs (with some assistance from Google), but that’s about it…

---

<div class="post-metadata">

**Author:** ![steve](https://forum.audacityteam.org/letter_avatar_proxy/v4/letter/s/f19dbf/32.png) [@steve](https://forum.audacityteam.org/u/steve)\
**Post date:** [August 15, 2021, 12:06pm UTC](https://forum.audacityteam.org/t/convert-label-to-cue-sheet-and-cue-sheet-to-label/19925/17 "2021-08-15T12:06:10Z")

</div>

This page isn’t working for me: [http://grimblefritz.com/audacity/cue2lbl.php](http://grimblefritz.com/audacity/cue2lbl.php)

---

<div class="post-metadata">

**Author:** ![grimblefritz](https://forum.audacityteam.org/letter_avatar_proxy/v4/letter/g/c68b51/32.png) [@grimblefritz](https://forum.audacityteam.org/u/grimblefritz)\
**Post date:** [August 15, 2021, 5:46pm UTC](https://forum.audacityteam.org/t/convert-label-to-cue-sheet-and-cue-sheet-to-label/19925/18 "2021-08-15T17:46:38Z")

</div>

> [@](#):
>
> Was your tool based on these bash scripts: [Missing features - Audacity Support](https://wiki.audacityteam.org/wiki/Cue_sheets#Bash_script_to_create_cue_sheet_from_labels)

No, that’s the first I’ve seen that. I started on mine in late 2009 and didn’t put it online until 2011. It’s overlapping work (in time) but definitely not derivative.

---

<div class="post-metadata">

**Author:** ![grimblefritz](https://forum.audacityteam.org/letter_avatar_proxy/v4/letter/g/c68b51/32.png) [@grimblefritz](https://forum.audacityteam.org/u/grimblefritz)\
**Post date:** [August 15, 2021, 5:53pm UTC](https://forum.audacityteam.org/t/convert-label-to-cue-sheet-and-cue-sheet-to-label/19925/19 "2021-08-15T17:53:41Z")

</div>

> [@](#):
>
> Sounds complicated! I assumed it would only be some PHP (and JS), but you apparently had a primary goal via shell…  
> …  
> I’m afraid I don’t fit the bill. I can tweak existing PHP / JS (CSS/HTML) to my needs (with some assistance from Google), but that’s about it…

I’m sure it could be rewritten in just about anything. PHP. Python. Rust. Whatever 🙂

It just happens that my first need was from the console and awk worked great. And then it was a natural evolution to front-end that with bash.

Then, sometime later, the idea hit me that I could make it available online as a service. So in true Unix fashion (which I started with back in 1982, after several years with a plethora of lesser-knowns) I used HTML+PHP to call an existing tool and parsed the return. So, basically, it’s a pipe, just on the net.

Anyway, not terribly complex, just obscure these days – except maybe to some old-school sysadmins.

---

<div class="post-metadata">

**Author:** ![grimblefritz](https://forum.audacityteam.org/letter_avatar_proxy/v4/letter/g/c68b51/32.png) [@grimblefritz](https://forum.audacityteam.org/u/grimblefritz)\
**Post date:** [August 15, 2021, 5:55pm UTC](https://forum.audacityteam.org/t/convert-label-to-cue-sheet-and-cue-sheet-to-label/19925/20 "2021-08-15T17:55:48Z")

</div>

> [@](#):
>
> This page isn’t working for me: [cue2lbl](http://grimblefritz.com/audacity/cue2lbl.php)

Blame my fat fingers. While looking at the code to try and remember what I wrote, I fixed a typo that was spewing a warning message to the logs for the last ten years.

And then didn’t test my fix since I was supposed to be out the door… and of course fat-fingered in an actual fatal.

Fixed, and fingers duly punished.

[Next page](https://forum.audacityteam.org/t/convert-label-to-cue-sheet-and-cue-sheet-to-label/19925.md?page=2)
