The Art of the Debussy (or how it looks like after the community cleanup)

The classical music community on MusicBrainz decided to concentrate on one composer and do a monthly cleanup of Debussy data in the database.

Here is the state of the database early September 2017 after the cleanup

Setup


In [1]:
composer_name = 'Claude Debussy'
composer_mbid = 'be50643c-0377-4968-b48c-47e06b2e2a3b'

In [2]:
%run startup.ipy


Last notebook update: 2018-06-06
Git repo: git@bitbucket.org:loujine/musicbrainz-dataviz.git
Importing libs
Defining database parameters

Defining *sql* helper function
Last database update: 2018-06-02

Python packages versions:
numpy       1.14.3
pandas      0.23.0
sqlalchemy  1.2.8
CPython 3.7.0b5
IPython 6.4.0

In [3]:
import datetime as dt
def to_unix_time(datestring):
    epoch =  dt.datetime(1970, 1, 1)
    return (dt.datetime.strptime(datestring, '%Y-%m-%d') - epoch).total_seconds() * 1000

Work list compared to IMSLP


In [4]:
def work_list(composer_name):
    composer = sql("""
SELECT gid AS mbid,
       name
  FROM artist
 WHERE name = %(composer_name)s;
    """, composer_name=composer_name)

    works = sql("""
SELECT w.name            AS work_name,
       lt.text_value     AS catalog_no,
       s.name            AS catalog,
       s.id              AS catalog_id,
       wt.name           AS work_type,
       la.name           AS language,
       watav.value       AS key,
       to_date(to_char(l.begin_date_year, '9999') ||
               to_char(COALESCE(l.end_date_month, 1), '99') ||
               to_char(COALESCE(l.end_date_day, 1), '99'), 'YYYY MM DD') AS start,
       to_date(to_char(l.end_date_year, '9999') ||
               to_char(COALESCE(l.end_date_month, 1), '99') ||
               to_char(COALESCE(l.end_date_day, 1), '99'), 'YYYY MM DD') AS end,
       w.gid             AS mbid
  FROM work          AS w
  JOIN l_artist_work AS law ON w.id = law.entity1
  JOIN artist        AS a   ON a.id = law.entity0
  JOIN link          AS l   ON l.id = law.link
LEFT OUTER JOIN l_series_work                     AS lsw ON w.id = lsw.entity1
LEFT OUTER JOIN series                            AS s   ON s.id = lsw.entity0
LEFT OUTER JOIN link_attribute_text_value         AS lt  ON lt.link = lsw.link
LEFT OUTER JOIN work_language                     AS wl  ON wl.work = w.id
LEFT OUTER JOIN language                          AS la  ON la.id = wl.language
LEFT OUTER JOIN work_type                         AS wt  ON w.type = wt.id
LEFT OUTER JOIN work_attribute                    AS wa  ON wa.work = w.id
LEFT OUTER JOIN work_attribute_type               AS wat   ON wat.id = wa.work_attribute_type
LEFT OUTER JOIN work_attribute_type_allowed_value AS watav ON watav.id = wa.work_attribute_type_allowed_value
 WHERE a.gid = %(composer_mbid)s
 ORDER BY start, work_name;
    """, composer_mbid=composer.mbid[0])

    works['url'] = works.mbid.apply(mb_work_link)
    return works

works = work_list('Claude Debussy')

In [5]:
print('Number of works: {}'.format(works.shape[0]))

print('10 first works:')
iplot(ff.create_table(works[['start', 'work_name', 'url']].head(10)))


Number of works: 1006
10 first works:

Debussy catalogue


In [6]:
composer = sql("""
SELECT gid AS mbid,
       name
  FROM artist
 WHERE name = %(composer_name)s;
""", composer_name='Claude Debussy')

#print(composer)

catno = sql("""
SELECT w.name            AS work_name,
       lt.text_value     AS catalog_no,
       url               AS imslp
  FROM work          AS w
  JOIN l_artist_work AS law ON w.id = law.entity1
  JOIN artist        AS a   ON a.id = law.entity0
  JOIN link          AS l   ON l.id = law.link
  JOIN l_series_work                     AS lsw ON w.id = lsw.entity1
  JOIN series                            AS s   ON s.id = lsw.entity0
  JOIN link_attribute_text_value         AS lt  ON lt.link = lsw.link
  LEFT OUTER JOIN l_url_work AS luw ON w.id = luw.entity1
  LEFT OUTER JOIN url        AS u   ON u.id = luw.entity0

 WHERE a.gid = %(composer_mbid)s
   -- AND s.gid = '8d45008f-a609-4b97-a038-eaf946b2533f'
   AND s.gid = 'ce1cbe59-d4e1-4d70-b0be-3c0131cddb15'
   AND url ILIKE '%%imslp%%'
 ORDER BY catalog_no;
""", composer_mbid=composer.mbid[0])

catno.index = catno.catalog_no
catno.drop('catalog_no', axis=1, inplace=True)
catno.head()
#iplot(ff.create_table(works[['start', 'work_name', 'url']].head(10)))


Out[6]:
work_name imslp
catalog_no
L. 100 Estampes, L. 100, CD 108 http://imslp.org/wiki/Estampes_(Debussy,_Claude)
L. 102 Trois Chansons de France, L. 102, CD 115 http://imslp.org/wiki/3_Chansons_de_France_(De...
L. 103 Deux danses pour Harpe et Orchestre, L. 103, C... http://imslp.org/wiki/Danse_sacr%C3%A9e_et_dan...
L. 104 Fêtes galantes (Deuxième recueil), L. 104, CD 114 http://imslp.org/wiki/F%C3%AAtes_galantes_(Deb...
L. 105 Masques, L. 105, CD 110 http://imslp.org/wiki/Masques_(Debussy%2C_Claude)

Comparison with works in IMLSP


In [7]:
imslp = pandas.read_html('http://imslp.org/wiki/List_of_works_by_Claude_Debussy', header=0, index_col=0)[0]

In [8]:
imslp.head()


Out[8]:
Lesure# (new) Year Genre Title Notes
Lesure#
L 1 NaN 1879 Vocal Ballade à la lune: C'était dans la nuit brune for voice and piano
L 2 CD 1 1879 Vocal Madrid: Madrid, princesse des Espagnes for voice and piano
L 3 CD 5 1879 Chamber Piano Trio in G major for piano, violin, and cello
L 4 CD 2 1880 Vocal Nuits d'étoiles: Nuit d'étoiles, sous tes voiles for voice and piano
L 5 CD 6 1880 Vocal Caprice: Quand je baise, pâle de fièvre for voice and piano

In [9]:
works.head()


Out[9]:
work_name catalog_no catalog catalog_id work_type language key start end mbid url
0 Ballade à la lune: C'était dans la nuit brune,... L. 1 Catalogue François Lesure des œuvres de Claude... 241.0 Song French None 1879-01-01 1879-01-01 79850af1-9fe2-4bbe-b149-1ed9294f60b0 <a href="https://musicbrainz.org/work/79850af1...
1 Madrid, L. 2, CD 1 "Madrid, princesse des Espa... CD 1 Catalogue François Lesure des œuvres de Claude... 242.0 Song French None 1879-01-01 1879-01-01 d1f003e0-061b-4000-aac0-e8c90d221763 <a href="https://musicbrainz.org/work/d1f003e0...
2 Madrid, L. 2, CD 1 "Madrid, princesse des Espa... L. 2 Catalogue François Lesure des œuvres de Claude... 241.0 Song French None 1879-01-01 1879-01-01 d1f003e0-061b-4000-aac0-e8c90d221763 <a href="https://musicbrainz.org/work/d1f003e0...
3 Aimons-nous et dormons, L. 16, CD 7 L. 16 Catalogue François Lesure des œuvres de Claude... 241.0 Song French None 1880-01-01 1880-01-01 bd010e97-8739-495b-8ced-943ca8c22168 <a href="https://musicbrainz.org/work/bd010e97...
4 Aimons-nous et dormons, L. 16, CD 7 CD 7 Catalogue François Lesure des œuvres de Claude... 242.0 Song French None 1880-01-01 1880-01-01 bd010e97-8739-495b-8ced-943ca8c22168 <a href="https://musicbrainz.org/work/bd010e97...

In [10]:
compar = imslp.copy()
compar['mbid'] = None

for idx, row in works.iterrows():
    if row.catalog_no and row.catalog_no.startswith('L'):
        try:        
            compar.loc[row.catalog_no.replace('. ', '')].mbid = row.mbid
        except:
            print('Lesure catalog in MB not found in IMSLP list: {0.catalog_no} (mbid {0.mbid})'.format(row))
            pass
    
print('Lesure catalog entries in IMSLP that do not have a mbid:')
compar[compar.mbid.isnull()]


Lesure catalog in MB not found in IMSLP list: L. 1 (mbid 79850af1-9fe2-4bbe-b149-1ed9294f60b0)
Lesure catalog in MB not found in IMSLP list: L. 2 (mbid d1f003e0-061b-4000-aac0-e8c90d221763)
Lesure catalog in MB not found in IMSLP list: L. 16 (mbid bd010e97-8739-495b-8ced-943ca8c22168)
Lesure catalog in MB not found in IMSLP list: L. 5 (mbid 9f223f1e-9841-46c4-b64f-731461a2ab11)
Lesure catalog in MB not found in IMSLP list: L. 4 (mbid 8f3a5ef3-5346-46d3-a4d9-9c1711588d87)
Lesure catalog in MB not found in IMSLP list: L. 8 (mbid c499ee89-f981-4e1c-b633-6687d17cffa5)
Lesure catalog in MB not found in IMSLP list: L. 10 (mbid bbb113ce-6806-42b7-afbd-963254f8ebda)
Lesure catalog in MB not found in IMSLP list: L. 9 (mbid c2b309aa-52e4-3f15-a009-2a0c12a476ff)
Lesure catalog in MB not found in IMSLP list: L. 3 (mbid 01d61d0c-fbbb-4db0-aecc-cbe965135c4e)
Lesure catalog in MB not found in IMSLP list: L. 47 (mbid c3ed41ad-4521-40ab-82f7-8a6299b554fe)
Lesure catalog in MB not found in IMSLP list: L. 7 (mbid 70161866-1bb6-4b9b-8032-3970788d97a7)
Lesure catalog in MB not found in IMSLP list: L. 20bis (mbid cb54194f-ba75-424f-9ff3-73fbbff23237)
Lesure catalog in MB not found in IMSLP list: L. 19 (mbid bec74574-8453-4dfb-a78e-6a15f1f214e4)
Lesure catalog in MB not found in IMSLP list: L. 33 (mbid ce6806e6-e401-497b-8b2c-0f207a449d21)
Lesure catalog in MB not found in IMSLP list: L. 48 (mbid 71e5de47-f9f9-4790-9f1c-8dd15ecb5f9c)
Lesure catalog in MB not found in IMSLP list: L. 46 (mbid e72625e6-576d-4ba8-916d-29762104225b)
Lesure catalog in MB not found in IMSLP list: L. 30 (mbid 094b15e2-137d-4d35-ac56-baa937f34ecf)
Lesure catalog in MB not found in IMSLP list: L. 17 (mbid 2077df2f-28ed-4816-b9c4-f401aa4ac6d2)
Lesure catalog in MB not found in IMSLP list: L. 18 (mbid 67707045-929d-4e61-ad48-dfff3ffe0d4f)
Lesure catalog in MB not found in IMSLP list: L. 11 (mbid db41b08d-81fa-4427-bd96-990173b159fd)
Lesure catalog in MB not found in IMSLP list: L. 12 (mbid 8778d01a-b4f0-4d59-bba3-5ccb1fdf8aca)
Lesure catalog in MB not found in IMSLP list: L. 35 (mbid d0f20dae-03cd-4142-9d00-68e679d16dc3)
Lesure catalog in MB not found in IMSLP list: L. 32 (mbid cb17578c-cbcd-4cee-86e0-19f4db3b928d)
Lesure catalog in MB not found in IMSLP list: L. 20 (mbid a1b42389-9b26-42da-b3dd-d18dbdf7f2f8)
Lesure catalog in MB not found in IMSLP list: L. 23 (mbid 862853e8-0b25-411f-946e-c7fe5a10515b)
Lesure catalog in MB not found in IMSLP list: L. 37 (mbid 32a08d0e-e38f-41c7-965c-4f4c4de0b326)
Lesure catalog in MB not found in IMSLP list: L. 38 (mbid 17320acd-cd07-426b-a726-92762e71453a)
Lesure catalog in MB not found in IMSLP list: L. 38 (mbid f1e6dde5-b55f-41d5-a6d9-6db036d62cfd)
Lesure catalog in MB not found in IMSLP list: L. 13 (mbid d21c604a-800a-4986-8013-4784236ea7e1)
Lesure catalog in MB not found in IMSLP list: L. 15 (mbid 92ee1c5e-2208-4558-af27-a6c983c8cb21)
Lesure catalog in MB not found in IMSLP list: L. 14 (mbid c5215bfb-2b3d-4fb7-9f86-251817b9ff53)
Lesure catalog in MB not found in IMSLP list: L. 34 (mbid cc146e86-29de-490a-a04a-2106782a8485)
Lesure catalog in MB not found in IMSLP list: L. 49 (mbid 8aaf9fd2-1ab9-4e8d-bb10-6a943fe9ae14)
Lesure catalog in MB not found in IMSLP list: L. 21 (mbid 929b960e-fec7-4222-85ef-40498b483dd1)
Lesure catalog in MB not found in IMSLP list: L. 22 (mbid 041fbe8d-4526-4fe1-bd95-6f7e154217cc)
Lesure catalog in MB not found in IMSLP list: L. 24 (mbid a709e091-4db0-4f6e-a387-bd6d9524a2c0)
Lesure catalog in MB not found in IMSLP list: L. 25 (mbid 87623a71-a800-442c-8567-0672fd589a91)
Lesure catalog in MB not found in IMSLP list: L. 26 (mbid c3f90466-ed18-40a1-bb6b-bcbf34b1a546)
Lesure catalog in MB not found in IMSLP list: L. 27 (mbid 3dca1a1b-bae9-46c3-b749-6c3a14a94abe)
Lesure catalog in MB not found in IMSLP list: L. 28 (mbid dd4d7e5d-cb4b-4008-abd4-b4cf7a39c1e9)
Lesure catalog in MB not found in IMSLP list: L. 29 (mbid 6d603dec-8fd3-467b-8cb6-799dfc20688c)
Lesure catalog in MB not found in IMSLP list: L. 42 (mbid 622cf2a1-654a-485b-ad69-bc302e0fd372)
Lesure catalog in MB not found in IMSLP list: L. 51 (mbid bd474906-f38e-445f-bc96-98dfaf26a750)
Lesure catalog in MB not found in IMSLP list: L. 31 (mbid c292f535-5ca7-4249-8f2e-8293479e203e)
Lesure catalog in MB not found in IMSLP list: L. 50 (mbid 82c0eba4-279c-400e-bc32-99f1553261a5)
Lesure catalog in MB not found in IMSLP list: L. 39 (mbid 555d46e4-5c95-4161-9e8d-e0d05b4a9faf)
Lesure catalog in MB not found in IMSLP list: L. 40 (mbid 67bbe5a5-5646-4539-ab69-cfbf472ab053)
Lesure catalog in MB not found in IMSLP list: L. 41 (mbid f248dabf-9e87-4844-955a-960355d50b2e)
Lesure catalog in MB not found in IMSLP list: L. 44 (mbid f2541181-f544-40fa-8b54-18d0080ef10c)
Lesure catalog in MB not found in IMSLP list: L. 43 (mbid de4e3a06-86c7-4141-a67f-d79f4c5d7a7d)
Lesure catalog in MB not found in IMSLP list: L. 45 (mbid 1a2e6108-7ac1-4747-8f4d-183298dac5a4)
Lesure catalog in MB not found in IMSLP list: L. 36 (mbid 7bfa040b-663b-487d-b1af-2bbdc0e18edd)
Lesure catalog in MB not found in IMSLP list: L. 57 (mbid 36e790a2-144d-4de7-8f2e-bb329e5f0138)
Lesure catalog in MB not found in IMSLP list: L. 52 (mbid 197ef639-029b-4b49-9228-ea283bdebec3)
Lesure catalog in MB not found in IMSLP list: L. 54 (mbid c9809295-9465-4d6f-a241-cd03ef34ba0b)
Lesure catalog in MB not found in IMSLP list: L. 55 (mbid d989b85a-fd47-43f0-8a9a-59985264886d)
Lesure catalog in MB not found in IMSLP list: L. 53 (mbid f41643d1-e2a9-4ca0-ba40-2130727bbedf)
Lesure catalog in MB not found in IMSLP list: L. 56 (mbid e9cec25e-697b-429f-96cc-9838edfe2f1b)
Lesure catalog in MB not found in IMSLP list: L. 58 (mbid 1d2f7aff-ea8a-4050-95f3-c439180ef56b)
Lesure catalog in MB not found in IMSLP list: L. 79 (mbid dd1861d2-72b2-436d-8e7d-fee6ee60f4a7)
Lesure catalog in MB not found in IMSLP list: L. 51 (mbid bd474906-f38e-445f-bc96-98dfaf26a750)
Lesure catalog in MB not found in IMSLP list: L. 59 (mbid 5ed7d610-8d6f-482b-a642-304ce248f2b4)
Lesure catalog in MB not found in IMSLP list: L. 60 (mbid 1d0e2100-95f9-46b4-b81f-6270c470efbd)
Lesure catalog in MB not found in IMSLP list: L. 60 (mbid c73c0741-7e8d-4b50-b16c-1f005f4fae4b)
Lesure catalog in MB not found in IMSLP list: L. 64 (mbid a4293137-c0af-428e-aa27-0302e1e10e7c)
Lesure catalog in MB not found in IMSLP list: L. 62 (mbid 40ce7425-f0f1-42e6-92e6-9d7af59acd74)
Lesure catalog in MB not found in IMSLP list: L. 61 (mbid 6231d93f-e485-4517-ac07-dbf325439ac8)
Lesure catalog in MB not found in IMSLP list: L. 61 (mbid f0acd2c8-dede-45fb-8b29-cafb40ff23db)
Lesure catalog in MB not found in IMSLP list: L. 65 (mbid db6b904f-b5ee-4e3c-a172-5aab4aa526e0)
Lesure catalog in MB not found in IMSLP list: L. 73 (mbid bccb3d23-4e75-43a4-b398-0133cfb1f998)
Lesure catalog in MB not found in IMSLP list: L. 63 (mbid d242de6d-9e3f-4547-b8ae-15b685bf7c54)
Lesure catalog in MB not found in IMSLP list: L. 70 (mbid f924696e-0f37-3557-bb40-7fe10448b0a2)
Lesure catalog in MB not found in IMSLP list: L. 6 (mbid b22cc511-fedd-3e09-a242-86245c1d2400)
Lesure catalog in MB not found in IMSLP list: L. 66 (mbid ede113fb-299f-4a1b-b2be-f96e44717b4d)
Lesure catalog in MB not found in IMSLP list: L. 77 (mbid e8df18a9-f695-41fd-af7c-e890deb97093)
Lesure catalog in MB not found in IMSLP list: L. 67 (mbid 12801889-c8c9-3cf5-9c4d-db3f119e8817)
Lesure catalog in MB not found in IMSLP list: L. 72 (mbid 92109472-6c02-4283-abce-03ca32fd8de8)
Lesure catalog in MB not found in IMSLP list: L. 68 (mbid 7158411f-d467-38ce-9d2d-338a5bf5a26e)
Lesure catalog in MB not found in IMSLP list: L. 75 (mbid 51c5a474-470e-48d8-a138-df81f568896a)
Lesure catalog in MB not found in IMSLP list: L. 69 (mbid 0a19903e-2525-36cb-8ee0-69d9a0a3cc40)
Lesure catalog in MB not found in IMSLP list: L. 71 (mbid f166206e-c5d2-3a21-b593-72ecf560fa04)
Lesure catalog in MB not found in IMSLP list: L. 74 (mbid af56a436-835b-4edf-a97f-de922709a254)
Lesure catalog in MB not found in IMSLP list: L. 80 (mbid 220f84a2-1a71-45f6-b245-c0c81b7e4c6f)
Lesure catalog in MB not found in IMSLP list: L. 81 (mbid 875158b5-7960-4d60-b9b2-4f613365afdb)
Lesure catalog in MB not found in IMSLP list: L. 86 (mbid 9e9d8173-2bca-347e-b19c-2057455e3fad)
Lesure catalog in MB not found in IMSLP list: L. 82 (mbid 65fdfe75-90e1-39fd-adbc-34f19fbf0f7a)
Lesure catalog in MB not found in IMSLP list: L. 85 (mbid 42dbb579-7781-4ba5-be5d-a662c4e4517b)
Lesure catalog in MB not found in IMSLP list: L. 83 (mbid 6acf9644-8aea-4748-98cb-723f2a1ada2f)
Lesure catalog in MB not found in IMSLP list: L. 76 (mbid 209b5602-3399-45ca-b2fd-f5783334023d)
Lesure catalog in MB not found in IMSLP list: L. 84 (mbid 187fd282-ae06-4888-9926-79f3abba5e29)
Lesure catalog in MB not found in IMSLP list: L. 77 (mbid b104559d-e2ec-4f9f-859c-37511183660c)
Lesure catalog in MB not found in IMSLP list: L. 88 (mbid 3d7bec68-2514-4852-b9b5-c02104a98dbd)
Lesure catalog in MB not found in IMSLP list: L. 87 (mbid 22b38581-2e90-4159-89ea-d2fbc908a07f)
Lesure catalog in MB not found in IMSLP list: L. 95 (mbid 3e401575-bb50-4a03-8ae1-33dece70a025)
Lesure catalog in MB not found in IMSLP list: L. 89 (mbid 39451601-8945-41c3-9dcb-408bf4026666)
Lesure catalog in MB not found in IMSLP list: L. 90 (mbid d3c7c847-31ae-477f-8409-72f4c3a99a96)
Lesure catalog in MB not found in IMSLP list: L. 91 (mbid 386d977f-4b1c-482e-b3a6-3a3e1a64fac2)
Lesure catalog in MB not found in IMSLP list: L. 92 (mbid efbad127-4df6-475b-a880-23aaaa9c1496)
Lesure catalog in MB not found in IMSLP list: L. 94 (mbid 0d3c3764-edb6-4f08-aa2f-15ca312fb165)
Lesure catalog in MB not found in IMSLP list: L. 93 (mbid 53e9814c-9666-4d34-b804-6f3d15360fa8)
Lesure catalog in MB not found in IMSLP list: L. 96 (mbid a58719c1-b067-41b8-9e36-70c08ee41207)
Lesure catalog in MB not found in IMSLP list: L. 98 (mbid 0bbd82ee-9cbb-40a5-82ff-da8d31e276ea)
Lesure catalog in MB not found in IMSLP list: L. 98 (mbid 257b45aa-92a0-3c96-83cb-633c9a302281)
Lesure catalog in MB not found in IMSLP list: L. 97 (mbid d695a425-86ab-4b57-a881-1915652b0a76)
Lesure catalog in MB not found in IMSLP list: L. 78 (mbid 41ca8ded-58b5-462a-9db4-a0a23adfe9c9)
Lesure catalog in MB not found in IMSLP list: L. 99 (mbid b3ddc7d1-50df-4292-957f-16c469d68153)
Lesure catalog in MB not found in IMSLP list: L. 57 (mbid 36e790a2-144d-4de7-8f2e-bb329e5f0138)
Lesure catalog in MB not found in IMSLP list: L. 92 (mbid efbad127-4df6-475b-a880-23aaaa9c1496)
Lesure catalog in MB not found in IMSLP list: L. 94 (mbid 0d3c3764-edb6-4f08-aa2f-15ca312fb165)
Lesure catalog in MB not found in IMSLP list: L. 84 (mbid 187fd282-ae06-4888-9926-79f3abba5e29)
Lesure catalog entries in IMSLP that do not have a mbid:
Out[10]:
Lesure# (new) Year Genre Title Notes mbid
Lesure#
L 1 NaN 1879 Vocal Ballade à la lune: C'était dans la nuit brune for voice and piano None
L 2 CD 1 1879 Vocal Madrid: Madrid, princesse des Espagnes for voice and piano None
L 3 CD 5 1879 Chamber Piano Trio in G major for piano, violin, and cello None
L 4 CD 2 1880 Vocal Nuits d'étoiles: Nuit d'étoiles, sous tes voiles for voice and piano None
L 5 CD 6 1880 Vocal Caprice: Quand je baise, pâle de fièvre for voice and piano None
L 6 CD 84 1880 Vocal Beau soir: Lorsque au soleil couchant les rivi... for voice and piano None
L 7 CD 16 1880 Vocal Fleur des blés: Le long des blés que la brise ... for voice and piano None
L 8 CD 3 1880 Vocal Rêverie: Le zéphir à la douce haleine for voice and piano None
L 9 CD 4 1880 Piano Danse bohémienne NaN None
L 10 CD 8 1880 Piano Symphony for piano, four hands NaN None
L 11 CD 18 1881 Vocal Souhait: Oh! quand la mort que rien ne saurait... for voice and piano None
L 12 CD 19 1881 Vocal Triolet à Phillis (Zéphyr): Si j'étais le zéph... for voice and piano None
L 13 CD 28 1881 Vocal Les roses: Lorsque le ciel de saphir for voice and piano None
L 14 CD 44 1881 Vocal Séguidille: Un jupon serré sur les hanches for voice and piano None
L 15 CD 30 1881 Vocal Pierrot: Le bon Pierrot que la foule contemple for voice and piano None
L 16 CD 7 1881 Vocal Aimons-nous et dormons for voice and piano None
L 17 CD 11 1881 Vocal Rondel chinois: Sur le lac bordé d'azalée for voice and piano None
L 18 CD 12 1881 Vocal Tragédie: Les petites fleurs n'ont pu vivre for voice and piano None
L 19 CD 13 1881 Vocal Jane: Je pâlis et tombe en langueur for voice and piano None
L 20 CD 35 1881 Vocal Daniel: Versez, que de l'ivresse. Aux accents ... for three soloists and orchestra None
L 20bis CD 14 1881 Choral Hélène: Franchis les mers icariennes for soprano, choir and orchestra None
L 21 CD 26 1882 Vocal Fantoches: Scaramouche et Pulcinella for voice and piano None
L 22 CD 36 1882 Vocal Le lilas: O floraison divine des lilas for voice and piano None
L 23 CD 31 1882 Vocal Fête galante: Voilà Sylvandre et Lycas et Myrtil for voice and piano None
L 24 CD 37 1882 Choral Printemps_L_24_(Debussy,_Claude): Salut printe... for female choir and orchestra None
L 25 CD 38 1882 Voice Flôts, palmes et sables: Loin des yeux du monde for voice and piano None
L 26 CD 39 1882 Piano/Cello Nocturne et Scherzo for piano and cello None
L 27 CD 40 1882 Cello/Orchestra Intermezzo for cello and orchestra None
L 28 CD 42 1882 Vocal En sourdine: Calmes dans le demi-jour for voice and piano None
L 29 CD 43 1882 Vocal Mandoline: Les donneurs de sérénades for voice and piano None
... ... ... ... ... ... ...
L 82 CD 89 1892 Piano Nocturne NaN None
L 83 CD 92 1892-93 Orchestral 3 Scènes au crépuscule NaN None
L 84 CD 90 1892-93 Vocal Proses lyriques De rêve: La nuit a des douceu... for voice and piano None
L 85 CD 91 1893 Chamber String Quartet in G minor Opus 10 None
L 86 CD 87 1894 Orchestral Prélude à l'après-midi d'un faune NaN None
L 87 CD 94 1894 Piano Images oubliées Lent (mélancolique et doux) ... "Souvenir" is early version of Sarabande from ... None
L 88 CD 93 1893-1902 Opera Pelléas et Mélisande NaN None
L 89 CD 96 1896-1900 Vocal La Saulaie for baritone and orchestra None
L 90 CD 97 1897-98 Vocal Chansons de Bilitis La flûte de pan: Pour le ... for voice and piano None
L 91 CD 98 1897-99 Orchestral Nocturnes Nuages Fêtes Sirènes for orchestra (and Female Choir, in Sirènes) None
L 92 CD 99 1898-1908 Choral Chansons de Charles d'Orléans Dieu! qu'il la ... for choir of four mixed voices a cappella None
L 93 CD100 1899 Vocal Berceuse: Il était une fois une fée qui avait ... for voice without accompaniment None
L 94 CD101 1899-1902 Vocal Nuits blanches: Tout à l'heure ses mains plus ... for voice and piano None
L 95 CD 95 1894-1901 Piano Pour le piano Prélude Sarabande Toccata suite for piano None
L 96 CD102 NaN Chamber Music for Chansons de Bilitis Chant pastoral ... for two flutes, two harps, and celesta None
L 97 CD103 1901 Piano Lindaraja for two pianos None
L 98 CD104 1901-11 Saxophone/Orchestra Rhapsody for Orchestra and Saxophone NaN None
L 99 CD112 1903 Piano D'un cahier d'esquisses NaN None
L105 CD134 1904 Piano Masques NaN None
L105 CD110 1903-04 Piano Morceau de Concours Same as L108 None
NaN NaN 1880 Piano Intermède NaN None
NaN CD 21 1881 Vocal Les Papillions for voice and piano None
NaN NaN 1884? Piano Fugue NaN None
NaN NaN 1911 ca. Organ 12 Pièces pour Grand Orgue (Transcriptions) None
NaN NaN 1915 Piano Étude retrouvée NaN None
NaN CD150 1917 Piano Les soirs illuminés par l'ardeur du charbon NaN None
NaN CD 9 1881 Vocal Les baiser: Plus de fois dans tes bras charmants for voice and piano None
NaN CD 10 1881 Piano Andante cantabile for piano, four hands NaN None
NaN CD 20 1881 Piano Diane Ouverture for piano, four hands NaN None
NaN CD 25 1881 Vocal Les Elfes for voice and piano None

114 rows × 6 columns

Relationship on recordings

Should contain only recordings where Debussy was a performer (pianist)


In [11]:
sql("""
SELECT COUNT(*)
  FROM recording          AS r
  JOIN l_artist_recording AS lar ON r.id = lar.entity1
  JOIN artist             AS a   ON a.id = lar.entity0
 WHERE a.gid = %(composer_mbid)s
""", composer_mbid=composer_mbid)


Out[11]:
count
0 31

Relationship on releases

The "composer" relation on releases is deprecated


In [12]:
sql("""
SELECT COUNT(*)
  FROM release            AS r
  JOIN l_artist_release   AS lar ON r.id = lar.entity1
  JOIN artist             AS a   ON a.id = lar.entity0
 WHERE a.gid = %(composer_mbid)s
""", composer_mbid=composer_mbid)


Out[12]:
count
0 0

As release group artist


In [13]:
sql("""
SELECT COUNT(*)
--       rg.name AS album,
--       ac.name AS artists,
--       rg.gid AS mbid
  FROM artist             AS a
  JOIN artist_credit_name AS acn ON a.id = acn.artist
  JOIN artist_credit      AS ac  ON ac.id = acn.artist_credit
  JOIN release_group      AS rg  ON rg.artist_credit = ac.id
--  JOIN release            AS r   ON r.release_group = rg.id
--  JOIN release_event      AS ev  ON ev.release = r.id
 WHERE a.gid = %(composer_mbid)s
   ;""", composer_mbid=composer_mbid)


Out[13]:
count
0 939

As recording artist

Should contain only recordings where Debussy was a performer (pianist)


In [14]:
sql("""
SELECT COUNT(*)
  FROM artist             AS a
  JOIN artist_credit_name AS acn ON a.id = acn.artist
  JOIN artist_credit      AS ac  ON ac.id = acn.artist_credit
  JOIN recording          AS r   ON r.artist_credit = ac.id
 WHERE a.gid = %(composer_mbid)s
   ;""", composer_mbid=composer_mbid)


Out[14]:
count
0 75

Edits history


In [15]:
df = sql("""
SELECT date_trunc('month', edit.open_time) AS date, 
       editor.name AS editor,
       COUNT(*) AS edit_count
  FROM artist
  JOIN edit_artist ON artist.id = edit_artist.artist
  JOIN edit        ON edit.id = edit_artist.edit
  JOIN editor      ON editor.id = edit.editor
 WHERE artist.gid = %(composer_mbid)s
--   AND edit.open_time >= '2017-07-01'
GROUP BY date, editor.name
ORDER BY date, edit_count DESC
   ;""", composer_mbid=composer_mbid)

df.date = df.date.apply(lambda x: x.date())
#df.index =df.date.apply(lambda x: x.date())
#df.drop('date', axis=1, inplace=True)
df.head()


Out[15]:
date editor edit_count
0 2001-07-01 lavendergreen 1
1 2001-12-01 jsumler 3
2 2002-01-01 FreeDB 1
3 2002-03-01 pLynx 1
4 2002-04-01 FreeDB 1

In [16]:
print('Total numbers of edits regarding Debussy in history: {}'.format(df.edit_count.sum()))


Total numbers of edits regarding Debussy in history: 71991

Edits frequency by month


In [17]:
edit_frequency = df[['date', 'edit_count']].groupby('date').sum()
print(edit_frequency.tail(10))
iplot({
    'data': [dict(type='bar', x=edit_frequency.index, y=edit_frequency.edit_count)],
    'layout': {'title': "Number of edits per month for {}".format(composer_name),
               'xaxis': {'title': 'Date',
                         'range': [to_unix_time('2012-10-01'), to_unix_time('2018-01-01')]},
               'yaxis': {'title': 'Number of edits'},
              }
})


            edit_count
date                  
2017-08-01       10910
2017-09-01        1969
2017-10-01         773
2017-11-01        1389
2017-12-01         331
2018-01-01         829
2018-02-01         548
2018-03-01        1133
2018-04-01         268
2018-05-01         562

Not very surpringly, the monthly peak was obtained during the community cleanup: nearly 11000 edits! Some people started working in July when the sprint was announced which explained the high number (more than 4500 edits)

Edits split by editor

Edits by editor and day (limited to editors with at least 500 edits on Debussy)


In [18]:
pt = df.pivot_table('edit_count', index='date', columns='editor', aggfunc='sum').fillna(0)
pt = pt.loc[:, lambda pt: pt.sum(0) > 500]
pt.head()


Out[18]:
editor CatCat Dibou ListMyCDs.com MajorLurker ProfChris Senax dosoe loujin monxton reosarevok spitzwegerich steinbdj stupidname tityron
date
2001-07-01 0.0 0.0 0.0 0.0 0.0 0.0 0.0 0.0 0.0 0.0 0.0 0.0 0.0 0.0
2001-12-01 0.0 0.0 0.0 0.0 0.0 0.0 0.0 0.0 0.0 0.0 0.0 0.0 0.0 0.0
2002-01-01 0.0 0.0 0.0 0.0 0.0 0.0 0.0 0.0 0.0 0.0 0.0 0.0 0.0 0.0
2002-03-01 0.0 0.0 0.0 0.0 0.0 0.0 0.0 0.0 0.0 0.0 0.0 0.0 0.0 0.0
2002-04-01 0.0 0.0 0.0 0.0 0.0 0.0 0.0 0.0 0.0 0.0 0.0 0.0 0.0 0.0

In [19]:
import datetime as dt
iplot({
    'data': [{'x': pt.index, 'y': pt[field],
              'name': field, 'type': 'bar'} for field in pt.columns],
    'layout': {'title': "Number of edits per month per editor",
               'xaxis': {'title': 'Date',
                         'range': [to_unix_time('2017-06-01'), to_unix_time('2017-10-31')]},
               'yaxis': {'title': 'Number of edits',
                         'range': [0, 6500]}
              }
})


Congrats stupidname and ListMyCDs.com!

Top 10 editors


In [20]:
pt.index = pandas.to_datetime(pt.index)

In [21]:
pt['2017-07-01':'2017-11-01'].sum().sort_values(ascending=False).head(10)


Out[21]:
editor
stupidname       5734.0
ListMyCDs.com    5514.0
loujin           2336.0
CatCat           1962.0
spitzwegerich    1079.0
reosarevok        792.0
steinbdj          414.0
MajorLurker       273.0
monxton           264.0
Dibou              90.0
dtype: float64