python中list转object
时间: 2023-10-17 19:01:15 浏览: 120
解决python使用list()时总是报错的问题
5星 · 资源好评率100%
在Python中,可以使用`list()`函数将数组(`array`)对象转换为列表(`list`)对象。例如,如果有一个名为`B`的数组对象,想要将其转换为列表对象,可以使用`B.tolist()`方法。这将返回一个包含数组元素的列表。<span class="em">1</span><span class="em">2</span><span class="em">3</span>
#### 引用[.reference_title]
- *1* [python报错: list object has no attribute shape的解决](https://download.csdn.net/download/weixin_38748721/13708867)[target="_blank" data-report-click={"spm":"1018.2226.3001.9630","extra":{"utm_source":"vip_chatgpt_common_search_pc_result","utm_medium":"distribute.pc_search_result.none-task-cask-2~all~insert_cask~default-1-null.142^v93^chatsearchT3_2"}}] [.reference_item style="max-width: 33.333333333333336%"]
- *2* [python中list转换为数组](https://blog.csdn.net/weixin_39852647/article/details/110193495)[target="_blank" data-report-click={"spm":"1018.2226.3001.9630","extra":{"utm_source":"vip_chatgpt_common_search_pc_result","utm_medium":"distribute.pc_search_result.none-task-cask-2~all~insert_cask~default-1-null.142^v93^chatsearchT3_2"}}] [.reference_item style="max-width: 33.333333333333336%"]
- *3* [python fft测试的使用 简述了python中fft的使用,并给出了python2测试代码示例](https://download.csdn.net/download/li171049/88225586)[target="_blank" data-report-click={"spm":"1018.2226.3001.9630","extra":{"utm_source":"vip_chatgpt_common_search_pc_result","utm_medium":"distribute.pc_search_result.none-task-cask-2~all~insert_cask~default-1-null.142^v93^chatsearchT3_2"}}] [.reference_item style="max-width: 33.333333333333336%"]
[ .reference_list ]
阅读全文