group_name = {
  ["00 - BOSS ON PARADE"] = "00 - BOSS ON PARADE";
  ["01 - DDR 1st"] = "01 - DDR 1st";
  ["02 - DDR 2ndMIX"] = "02 - DDR 2ndMIX";
  ["03 - DDR 3rdMIX"] = "03 - DDR 3rdMIX";
  ["04 - DDR 4thMIX"] = "04 - DDR 4thMIX";
  ["05 - DDR 5thMIX"] = "05 - DDR 5thMIX";
  ["06 - DDR MAX"] = "06 - DDR MAX";
  ["07 - DDR MAX2"] = "07 - DDR MAX2";
  ["08 - DDR EXTREME"] = "08 - DDR EXTREME";
  ["09 - DDR SuperNOVA"] = "09 - DDR SuperNOVA";
  ["10 - DDR SuperNOVA2"] = "10 - DDR SuperNOVA2";
  ["11 - DDR X"] = "11 - DDR X";
  ["12 - DDR X2"] = "12 - DDR X2";
  ["13 - DDR X3 vs 2ndMIX"] = "13 - DDR X3 vs 2ndMIX";
  ["14 - DDR 2013"] = "14 - DDR 2013";
  ["15 - DDR 2014"] = "15 - DDR 2014";
  ["16 - DDR A"] = "16 - DDR A";
  ["17 - DDR A20"] = "17 - DDR A20";
  ["18 - DDR SuperNOVA3"] = "18 - DDR SuperNOVA3";
  ["19 - DDR XX"] = "19 - DDR XX";

  --ABC
  ["0-9"] = "0-9";
  ["A"] = "A";
  ["B"] = "B";
  ["C"] = "C";
  ["D"] = "D";
  ["E"] = "E";
  ["F"] = "F";
  ["G"] = "G";
  ["H"] = "H";
  ["I"] = "I";
  ["J"] = "J";
  ["K"] = "H";
  ["L"] = "L";
  ["M"] = "M";
  ["N"] = "N";
  ["O"] = "O";
  ["P"] = "P";
  ["Q"] = "Q";
  ["R"] = "R";
  ["S"] = "S";
  ["T"] = "T";
  ["U"] = "U";
  ["V"] = "V";
  ["W"] = "W";
  ["X"] = "X";
  ["Y"] = "Y";
  ["Z"] = "Z";
  ["Other"] = "NA";

  --bpm
  ["000-019"] = "000";
  ["020-039"] = "020";
  ["040-059"] = "040";
  ["060-079"] = "060";
  ["080-099"] = "080";
  ["100-119"] = "100";
  ["120-139"] = "120";
  ["140-159"] = "140";
  ["160-179"] = "160";
  ["180-199"] = "180";
  ["200-219"] = "200";
  ["220-239"] = "220";
  ["240-259"] = "240";
  ["260-279"] = "260";
  ["280-299"] = "280";
  ["300-319"] = "300";
  ["320-339"] = "320";
  ["340-359"] = "340";
  ["360-379"] = "360";
  ["380-399"] = "380";
  ["400-419"] = "400";
  ["420-439"] = "420";
  ["440-459"] = "440";
  ["460-479"] = "460";
  ["480-499"] = "480";
  ["500-519"] = "500";
  ["520-539"] = "520";
  ["540-559"] = "540";
  ["560-579"] = "560";
  ["580-599"] = "580";
  ["600-619"] = "600";
  ["620-639"] = "620";
  ["640-659"] = "640";
  ["660-679"] = "660";
  ["680-699"] = "680";
  ["700-719"] = "700";
  ["720-739"] = "720";
  ["740-759"] = "740";
  ["760-779"] = "760";
  ["780-799"] = "780";
  ["800-819"] = "800";
  ["820-839"] = "820";
  ["840-859"] = "840";
  ["860-879"] = "860";
  ["880-899"] = "880";
  ["900-919"] = "900";
  ["920-939"] = "920";
  ["940-959"] = "940";
  ["960-979"] = "960";
  ["980-999"] = "980";
  ["1000-1019"] = "a1000";

  --Meter
  ["01"] = "01";
  ["02"] = "02";
  ["03"] = "03";
  ["04"] = "04";
  ["05"] = "05";
  ["06"] = "06";
  ["07"] = "07";
  ["08"] = "08";
  ["09"] = "09";
  ["10"] = "10";
  ["11"] = "11";
  ["12"] = "12";
  ["13"] = "13";
  ["14"] = "14";
  ["15"] = "15";
  ["16"] = "16";
  ["17"] = "17";
  ["18"] = "18";
  ["19"] = "19";
  ["20"] = "20";
  ["N/A"] = "NA";

  --Grade
  ["???"] = "NA";
  ["   D x 9"] = "D";
  ["   D x 8"] = "D";
  ["   D x 7"] = "D";
  ["   D x 6"] = "D";
  ["   D x 5"] = "D";
  ["   D x 4"] = "D";
  ["   D x 3"] = "D";
  ["   D x 2"] = "D";
  ["   D x 1"] = "D";
  ["   C x 9"] = "C";
  ["   C x 8"] = "C";
  ["   C x 7"] = "C";
  ["   C x 6"] = "C";
  ["   C x 5"] = "C";
  ["   C x 4"] = "C";
  ["   C x 3"] = "C";
  ["   C x 2"] = "C";
  ["   C x 1"] = "C";
  ["   B x 9"] = "B";
  ["   B x 8"] = "B";
  ["   B x 7"] = "B";
  ["   B x 6"] = "B";
  ["   B x 5"] = "B";
  ["   B x 4"] = "B";
  ["   B x 3"] = "B";
  ["   B x 2"] = "B";
  ["   B x 1"] = "B";
  ["   A x 9"] = "A";
  ["   A x 8"] = "A";
  ["   A x 7"] = "A";
  ["   A x 6"] = "A";
  ["   A x 5"] = "A";
  ["   A x 4"] = "A";
  ["   A x 3"] = "A";
  ["   A x 2"] = "A";
  ["   A x 1"] = "A";
  ["  AA x 9"] = "2A";
  ["  AA x 8"] = "2A";
  ["  AA x 7"] = "2A";
  ["  AA x 6"] = "2A";
  ["  AA x 5"] = "2A";
  ["  AA x 4"] = "2A";
  ["  AA x 3"] = "2A";
  ["  AA x 2"] = "2A";
  ["  AA x 1"] = "2A";
  [" AAA x 9"] = "3A";
  [" AAA x 8"] = "3A";
  [" AAA x 7"] = "3A";
  [" AAA x 6"] = "3A";
  [" AAA x 5"] = "3A";
  [" AAA x 4"] = "3A";
  [" AAA x 3"] = "3A";
  [" AAA x 2"] = "3A";
  [" AAA x 1"] = "3A";
  ["AAAA x 9"] = "3A";
  ["AAAA x 8"] = "3A";
  ["AAAA x 7"] = "3A";
  ["AAAA x 6"] = "3A";
  ["AAAA x 5"] = "3A";
  ["AAAA x 4"] = "3A";
  ["AAAA x 3"] = "3A";
  ["AAAA x 2"] = "3A";
  ["AAAA x 1"] = "3A";

  --Genre
  ["POP"] = "Pop";
  ["UMU"] = "UMU";
  ["VARIETY"] = "Variety";
  ["NA"] = "NA";
};

group_rename = {
  ["00 - BOSS ON PARADE"] = "BOSS ON PARADE";
  ["01 - DDR 1st"] = "DDR 1st";
  ["02 - DDR 2ndMIX"] = "DDR 2ndMIX";
  ["03 - DDR 3rdMIX"] = "DDR 3rdMIX";
  ["04 - DDR 4thMIX"] = "DDR 4thMIX";
  ["05 - DDR 5thMIX"] = "DDR 5thMIX";
  ["06 - DDR MAX"] = "DDR MAX";
  ["07 - DDR MAX2"] = "DDR MAX2";
  ["08 - DDR EXTREME"] = "DDR EXTREME";
  ["09 - DDR SuperNOVA"] = "DDR SuperNOVA";
  ["10 - DDR SuperNOVA2"] = "DDR SuperNOVA2";
  ["11 - DDR X"] = "DDR X";
  ["12 - DDR X2"] = "DDR X2";
  ["13 - DDR X3 vs 2ndMIX"] = "DDR X3 vs 2ndMIX";
  ["14 - DDR 2013"] = "DDR 2013";
  ["15 - DDR 2014"] = "DDR 2014";
  ["16 - DDR A"] = "DDR A";
  ["17 - DDR A20"] = "DDR A20";
  ["18 - DDR SuperNOVA3"] = "DDR SuperNOVA3";
  ["19 - DDR XX"] = "DDR XX";
  ["00 - BOSS ON PARADE"] = "BOSS ON PARADE";

  ["0-9"] = "0-9";
  ["A"] = "A";
  ["B"] = "B";
  ["C"] = "C";
  ["D"] = "D";
  ["E"] = "E";
  ["F"] = "F";
  ["G"] = "G";
  ["H"] = "H";
  ["I"] = "I";
  ["J"] = "J";
  ["K"] = "H";
  ["L"] = "L";
  ["M"] = "M";
  ["N"] = "N";
  ["O"] = "O";
  ["P"] = "P";
  ["Q"] = "Q";
  ["R"] = "R";
  ["S"] = "S";
  ["T"] = "T";
  ["U"] = "U";
  ["V"] = "V";
  ["W"] = "W";
  ["X"] = "X";
  ["Y"] = "Y";
  ["Z"] = "Z";
  ["Other"] = "Misc.";

  --bpm
  ["000-019"] = "000";
  ["020-039"] = "020";
  ["040-059"] = "040";
  ["060-079"] = "060";
  ["080-099"] = "080";
  ["100-119"] = "100";
  ["120-139"] = "120";
  ["140-159"] = "140";
  ["160-179"] = "160";
  ["180-199"] = "180";
  ["200-219"] = "200";
  ["220-239"] = "220";
  ["240-259"] = "240";
  ["260-279"] = "260";
  ["280-299"] = "280";
  ["300-319"] = "300";
  ["320-339"] = "320";
  ["340-359"] = "340";
  ["360-379"] = "360";
  ["380-399"] = "380";
  ["400-419"] = "400";
  ["420-439"] = "420";
  ["440-459"] = "440";
  ["460-479"] = "460";
  ["480-499"] = "480";
  ["500-519"] = "500";
  ["520-539"] = "520";
  ["540-559"] = "540";
  ["560-579"] = "560";
  ["580-599"] = "580";
  ["600-619"] = "600";
  ["620-639"] = "620";
  ["640-659"] = "640";
  ["660-679"] = "660";
  ["680-699"] = "680";
  ["700-719"] = "700";
  ["720-739"] = "720";
  ["740-759"] = "740";
  ["760-779"] = "760";
  ["780-799"] = "780";
  ["800-819"] = "800";
  ["820-839"] = "820";
  ["840-859"] = "840";
  ["860-879"] = "860";
  ["880-899"] = "880";
  ["900-919"] = "900";
  ["920-939"] = "920";
  ["940-959"] = "940";
  ["960-979"] = "960";
  ["980-999"] = "980";
  ["1000-1019"] = "a1000";

  --Meter
  ["01"] = "01";
  ["02"] = "02";
  ["03"] = "03";
  ["04"] = "04";
  ["05"] = "05";
  ["06"] = "06";
  ["07"] = "07";
  ["08"] = "08";
  ["09"] = "09";
  ["10"] = "10";
  ["11"] = "11";
  ["12"] = "12";
  ["13"] = "13";
  ["14"] = "14";
  ["15"] = "15";
  ["16"] = "16";
  ["17"] = "17";
  ["18"] = "18";
  ["19"] = "19";
  ["20"] = "20";
  ["N/A"] = "N/A";

  --Grade
  ["?"] = "N/A";
  ["???"] = "N/A";
  ["   D x 9"] = "D";
  ["   D x 8"] = "D";
  ["   D x 7"] = "D";
  ["   D x 6"] = "D";
  ["   D x 5"] = "D";
  ["   D x 4"] = "D";
  ["   D x 3"] = "D";
  ["   D x 2"] = "D";
  ["   D x 1"] = "D";
  ["   C x 9"] = "C";
  ["   C x 8"] = "C";
  ["   C x 7"] = "C";
  ["   C x 6"] = "C";
  ["   C x 5"] = "C";
  ["   C x 4"] = "C";
  ["   C x 3"] = "C";
  ["   C x 2"] = "C";
  ["   C x 1"] = "C";
  ["   B x 9"] = "B";
  ["   B x 8"] = "B";
  ["   B x 7"] = "B";
  ["   B x 6"] = "B";
  ["   B x 5"] = "B";
  ["   B x 4"] = "B";
  ["   B x 3"] = "B";
  ["   B x 2"] = "B";
  ["   B x 1"] = "B";
  ["   A x 9"] = "A";
  ["   A x 8"] = "A";
  ["   A x 7"] = "A";
  ["   A x 6"] = "A";
  ["   A x 5"] = "A";
  ["   A x 4"] = "A";
  ["   A x 3"] = "A";
  ["   A x 2"] = "A";
  ["   A x 1"] = "A";
  ["  AA x 9"] = "AA";
  ["  AA x 8"] = "AA";
  ["  AA x 7"] = "AA";
  ["  AA x 6"] = "AA";
  ["  AA x 5"] = "AA";
  ["  AA x 4"] = "AA";
  ["  AA x 3"] = "AA";
  ["  AA x 2"] = "AA";
  ["  AA x 1"] = "AA";
  [" AAA x 9"] = "AAA";
  [" AAA x 8"] = "AAA";
  [" AAA x 7"] = "AAA";
  [" AAA x 6"] = "AAA";
  [" AAA x 5"] = "AAA";
  [" AAA x 4"] = "AAA";
  [" AAA x 3"] = "AAA";
  [" AAA x 2"] = "AAA";
  [" AAA x 1"] = "AAA";
  ["AAAA x 9"] = "AAAA";
  ["AAAA x 8"] = "AAAA";
  ["AAAA x 7"] = "AAAA";
  ["AAAA x 6"] = "AAAA";
  ["AAAA x 5"] = "AAAA";
  ["AAAA x 4"] = "AAAA";
  ["AAAA x 3"] = "AAAA";
  ["AAAA x 2"] = "AAAA";
  ["AAAA x 1"] = "AAAA";

  ["POP"] = "Pop";
  ["UMU"] = "UMU";
  ["VARIETY"] = "Variety";
  ["NA"] = "NA";
};

group_colors= {
  ["00 - BOSS ON PARADE"] = "#d90099";
	["01 - DDR 1st"]= "#b4e556",
	["02 - DDR 2ndMIX"]= "#eb8bc8",
	["03 - DDR 3rdMIX"]= "#fdf380",
	["04 - DDR 4thMIX"]= "#a592d5",
	["05 - DDR 5thMIX"]= "#12d0f2",
	["06 - DDR MAX"]= "#ffbe32",
	["07 - DDR MAX2"]= "#fa4b3c",
	["08 - DDR EXTREME"]= "#81f1a9",
	["09 - DDR SuperNOVA"]= "#fa4b3c",
	["10 - DDR SuperNOVA2"]= "#12cff2",
	["11 - DDR X"]= "#ffbe32",
	["12 - DDR X2"]= "#eb8cc8",
	["13 - DDR X3 vs 2ndMIX"]= "#16b5ef",
	["14 - DDR 2013"]= "#69ebca",
	["15 - DDR 2014"]= "#69ebca",
  ["16 - DDR A"]= "#16b5ef",
  ["18 - DDR SuperNOVA3"]= "#81f1a9",
  ["19 - DDR XX"]= "#16b5ef",
	-- genre/bemani series sort
	["Pop"]= "#ffbe32",
	["Anime/Game"]=	"#fff582",
	["Variety"]= "#eb8cc8",
	["GUMI 5th anniversary"]=	"#b8e267",
	["U.M.U. x BEMANI"]= "#fbafb4",
	["KONAMI originals"]= "#fa4b3c",
};

CDImage = {
	["Boys"]= "01",
	["Butterfly"]= "02",
	["I Believe In Miracles (The Lisa Marie Experience Radio Edit)"]= "03",
	["Little Bitch"]= "04",
	["MAKE IT BETTER"]= "05",
	["PARANOiA"]= "06",
	["PARANOiA MAX～DIRTY MIX～"]= "07",
	["PARANOiA MAX~DIRTY MIX~ (in roulette)"]= "07",
	["PUT YOUR FAITH IN ME"]= "08",
	["AM-3P"]= "09",
	["stomp to my beat"]= "10",
	["TRIP MACHINE"]= "11",
	["EL RITMO TROPICAL"]= "12",
	["BRILLIANT 2U"]= "13",
	["BAD GIRLS"]= "14",
	["Boom Boom Dollar (Red Monster Mix)"]= "15",
	["DUB-I-DUB"]= "16",
	["SP-TRIP MACHINE~JUNGLE MIX~"]= "17",
	["Have You Never Been Mellow"]= "18",
	["KUNG FU FIGHTING"]= "19",
	["My Fire (UKS Remix)"]= "20",
	["LET'S GET DOWN"]= "21",
	["That's The Way (I Like It)"]= "22",
	["PUT YOUR FAITH IN ME (Jazzy Groove)"]= "24",
	["BRILLIANT 2U(Orchestra Groove)"]= "25",
};
