python 簡單的数据格式转换轉換

#!/usr/bin/env Python3
# -*- coding: utf-8 -*-
# @Software: PyCharm
# @virtualenv:workon
# @contact: 1040691703@qq.com
# @Desc:Code descripton
__author__ = '未昔/AngelFate'
__date__ = '2019/12/17 12:09'
import pandas as pd

class JsonData():
    def __init__(self):
        pass
    def Zh(self):
        csv_name = './LiePing_data/20191217-110034.csv'
        json_name = csv_name.replace('.csv','_pd.json')
        data = pd.read_csv(csv_name)
        # data = pd.read_csv('./LiePing_data/20191217-110034.csv',encoding='utf8')
        print(data.head())
        data.to_json(json_name,force_ascii=False)
        
        read_json = pd.read_json(json_name)
        print(read_json.head())