专栏名称: 机器学习研究会
机器学习研究会是北京大学大数据与机器学习创新中心旗下的学生组织,旨在构建一个机器学习从事者交流的平台。除了及时分享领域资讯外,协会还会举办各种业界巨头/学术神牛讲座、学术大牛沙龙分享会、real data 创新竞赛等活动。
目录
相关文章推荐
机器学习研究组订阅  ·  16张H100训26分钟,超越o1-prev ... ·  12 小时前  
黄建同学  ·  John Rush对24+种AI编码 ... ·  昨天  
爱可可-爱生活  ·  【Claude和o3 ... ·  昨天  
黄建同学  ·  Qwen2.5-Max真的可以!Chatbo ... ·  2 天前  
量子位  ·  DeepSeek华为火线联手!硅基流动首发即 ... ·  4 天前  
51好读  ›  专栏  ›  机器学习研究会

【推荐】Python实用代码片段集锦

机器学习研究会  · 公众号  · AI  · 2017-12-03 21:19

正文



点击上方 “机器学习研究会” 可以订阅
摘要

转自:爱可可-爱生活

Snippets

  • string_import.py example to show import module from string

  • classtools.py assorted class utilities and tools

  • formats.py various specialized string display formatting utilities.

  • mydir.py a module that lists the namespaces of other module

  • mymap.py different ways of implementing map

  • myzip.py different ways of implementing zip

  • permute.py implemented permute

  • reloadall.py transitively reload nested module

  • scramble.py a iterable scrambler

  • streams.py give me reader, writer and a converter

  • timer.py Homegrown timing tools for function calls.

  • timer2.py Homegrown timing tools for function calls.

  • timer3.py Homegrown timing tools for function calls.

  • classtree.py Climb inheritance tree using namespace links, displaying higher superclasses with indentation for height







请到「今天看啥」查看全文