查看返回的ContourSet的collections属性。特别是第一个集合的get_paths()方法返回组成每个线段的成对点。
cs.collections[0].get_paths()
要获取坐标的NumPy数组,请使用
Path.vertices属性。
p1 = cs.collections[0].get_paths()[0] # grab the 1st pathcoor_p1 = p1.vertices

查看返回的ContourSet的collections属性。特别是第一个集合的get_paths()方法返回组成每个线段的成对点。
cs.collections[0].get_paths()
要获取坐标的NumPy数组,请使用
Path.vertices属性。
p1 = cs.collections[0].get_paths()[0] # grab the 1st pathcoor_p1 = p1.vertices