fengjiqiang / LSTM-Wind-Speed-Forecasting

LSTM to predict wind speed
47 stars 26 forks source link

AttributeError: 'DatetimeIndex' object has no attribute 'get_duplicates' #6

Open kongzue opened 1 year ago

kongzue commented 1 year ago

An error has occurred and I need help:

LSTM-Wind-Speed-Forecasting-master/LSTM-Wind-Speed-Forecasting-master/cnn.py", line 50, in drop_duplicates
    print("Number of duplicates: {}".format(len(df.index.get_duplicates())))
AttributeError: 'DatetimeIndex' object has no attribute 'get_duplicates'
fengjiqiang commented 1 year ago

可能是pandas的版本问题 这个api更新了 可以去查一下文档 https://pypandas.cn/docs/reference.html

kongzue commented 1 year ago

好的麻烦了,方便的话可以告诉我当时使用的版本么?


发件人: Jacob Feng @.> 发送时间: 2023年2月22日 2:14 收件人: fengjiqiang/LSTM-Wind-Speed-Forecasting @.> 抄送: Kongzue @.>; Author @.> 主题: Re: [fengjiqiang/LSTM-Wind-Speed-Forecasting] AttributeError: 'DatetimeIndex' object has no attribute 'get_duplicates' (Issue #6)

可能是pandas的版本问题 这个api更新了 可以去查一下文档 https://pypandas.cn/docs/reference.htmlhttps://aus01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fpypandas.cn%2Fdocs%2Freference.html&data=05%7C01%7C%7C73bc7969662f4f6936d208db147a866e%7C84df9e7fe9f640afb435aaaaaaaaaaaa%7C1%7C0%7C638126288713521958%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C3000%7C%7C%7C&sdata=nz6dJWKwCFDY%2FUra2Gb0WbHpFN9BZ7cJMs%2B6O3YxwCE%3D&reserved=0

― Reply to this email directly, view it on GitHubhttps://aus01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Ffengjiqiang%2FLSTM-Wind-Speed-Forecasting%2Fissues%2F6%23issuecomment-1439339843&data=05%7C01%7C%7C73bc7969662f4f6936d208db147a866e%7C84df9e7fe9f640afb435aaaaaaaaaaaa%7C1%7C0%7C638126288713521958%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C3000%7C%7C%7C&sdata=KoVZ0ziNdt7tcbw5aM4NrNL%2FyAE8TnBR3Zvehawy9wY%3D&reserved=0, or unsubscribehttps://aus01.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fnotifications%2Funsubscribe-auth%2FACNFSHZGW3LYMFWJTQBY2LDWYVZAHANCNFSM6AAAAAAVDDBT64&data=05%7C01%7C%7C73bc7969662f4f6936d208db147a866e%7C84df9e7fe9f640afb435aaaaaaaaaaaa%7C1%7C0%7C638126288713521958%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C3000%7C%7C%7C&sdata=L8r21FnZ5mJO9pHmeMSNe2i%2BjQNWYBFShxLGcCU%2B9E8%3D&reserved=0. You are receiving this because you authored the thread.Message ID: @.***>

fengjiqiang commented 1 year ago

时间太久忘记了 你可以用现有的api去实现这个小功能