如何把DataFrame中以list类型存放的单元进行纵向展开?

原表:

>>>pd.DataFrame({'id':['X','Y'],'value':[['A','B','C'],['B','D']]})
  id      value
0  X  [A, B, C]
1  Y     [B, D]

目标表:

>>>pd.DataFrame({'id':['X','X','X','Y','Y'],'value':['A','B','C','B','D']})
  id value
0  X     A
1  X     B
2  X     C
3  Y     B
4  Y     D
>>>df.explode('value', ignore_index=True)