积分充值
 首页
前端开发
AngularDartElectronFlutterHTML/CSSJavaScriptReactSvelteTypeScriptVue.js构建工具
后端开发
.NetC#C++C语言DenoffmpegGoIdrisJavaJuliaKotlinLeanMakefilenimNode.jsPascalPHPPythonRISC-VRubyRustSwiftUML其它语言区块链开发测试微服务敏捷开发架构设计汇编语言
数据库
Apache DorisApache HBaseCassandraClickHouseFirebirdGreenplumMongoDBMySQLPieCloudDBPostgreSQLRedisSQLSQLiteTiDBVitess数据库中间件数据库工具数据库设计
系统运维
AndroidDevOpshttpdJenkinsLinuxPrometheusTraefikZabbix存储网络与安全
云计算&大数据
Apache APISIXApache FlinkApache KarafApache KyuubiApache OzonedaprDockerHadoopHarborIstioKubernetesOpenShiftPandasrancherRocketMQServerlessService MeshVirtualBoxVMWare云原生CNCF机器学习边缘计算
综合其他
BlenderGIMPKiCadKritaWeblate产品与服务人工智能亿图数据可视化版本控制笔试面试
文库资料
前端
AngularAnt DesignBabelBootstrapChart.jsCSS3EchartsElectronHighchartsHTML/CSSHTML5JavaScriptJerryScriptJestReactSassTypeScriptVue前端工具小程序
后端
.NETApacheC/C++C#CMakeCrystalDartDenoDjangoDubboErlangFastifyFlaskGinGoGoFrameGuzzleIrisJavaJuliaLispLLVMLuaMatplotlibMicronautnimNode.jsPerlPHPPythonQtRPCRubyRustR语言ScalaShellVlangwasmYewZephirZig算法
移动端
AndroidAPP工具FlutterFramework7HarmonyHippyIoniciOSkotlinNativeObject-CPWAReactSwiftuni-appWeex
数据库
ApacheArangoDBCassandraClickHouseCouchDBCrateDBDB2DocumentDBDorisDragonflyDBEdgeDBetcdFirebirdGaussDBGraphGreenPlumHStreamDBHugeGraphimmudbIndexedDBInfluxDBIoTDBKey-ValueKitDBLevelDBM3DBMatrixOneMilvusMongoDBMySQLNavicatNebulaNewSQLNoSQLOceanBaseOpenTSDBOracleOrientDBPostgreSQLPrestoDBQuestDBRedisRocksDBSequoiaDBServerSkytableSQLSQLiteTiDBTiKVTimescaleDBYugabyteDB关系型数据库数据库数据库ORM数据库中间件数据库工具时序数据库
云计算&大数据
ActiveMQAerakiAgentAlluxioAntreaApacheApache APISIXAPISIXBFEBitBookKeeperChaosChoerodonCiliumCloudStackConsulDaprDataEaseDC/OSDockerDrillDruidElasticJobElasticSearchEnvoyErdaFlinkFluentGrafanaHadoopHarborHelmHudiInLongKafkaKnativeKongKubeCubeKubeEdgeKubeflowKubeOperatorKubernetesKubeSphereKubeVelaKumaKylinLibcloudLinkerdLonghornMeiliSearchMeshNacosNATSOKDOpenOpenEBSOpenKruiseOpenPitrixOpenSearchOpenStackOpenTracingOzonePaddlePaddlePolicyPulsarPyTorchRainbondRancherRediSearchScikit-learnServerlessShardingSphereShenYuSparkStormSupersetXuperChainZadig云原生CNCF人工智能区块链数据挖掘机器学习深度学习算法工程边缘计算
UI&美工&设计
BlenderKritaSketchUI设计
网络&系统&运维
AnsibleApacheAWKCeleryCephCI/CDCurveDevOpsGoCDHAProxyIstioJenkinsJumpServerLinuxMacNginxOpenRestyPrometheusServertraefikTrafficUnixWindowsZabbixZipkin安全防护系统内核网络运维监控
综合其它
文章资讯
 上传文档  发布文章  登录账户
IT文库
  • 综合
  • 文档
  • 文章

无数据

分类

全部后端开发(308)Python(308)Django(85)Scrapy(62)Celery(37)Jupyter(32)Tornado(20)Conda(16)ORM(14)Flask(2)

语言

全部英语(304)中文(简体)(3)英语(1)

格式

全部PDF文档 PDF(171)其他文档 其他(137)
 
本次搜索耗时 0.416 秒,为您找到相关结果约 308 个.
  • 全部
  • 后端开发
  • Python
  • Django
  • Scrapy
  • Celery
  • Jupyter
  • Tornado
  • Conda
  • ORM
  • Flask
  • 全部
  • 英语
  • 中文(简体)
  • 英语
  • 全部
  • PDF文档 PDF
  • 其他文档 其他
  • 默认排序
  • 最新排序
  • 页数排序
  • 大小排序
  • 全部时间
  • 最近一天
  • 最近一周
  • 最近一个月
  • 最近三个月
  • 最近半年
  • 最近一年
  • pdf文档 Python3 基础教程 - 廖雪峰

    com/ 112/531 而节省大量的空间。在 Python 中,这种一边循环一边计算的机制,称 为生成器:generator。 要创建一个 generator,有很多种方法。第一种方法很简单,只要把一个 列表生成式的[]改成(),就创建了一个 generator: >>> L = [x * x for x in range(10)] >>> L [0, 1, 4, 9, 16 g <generator object at 0x1022ef630> 创建 L 和 g 的区别仅在于最外层的[]和(),L 是一个 list,而 g 是一个 generator。 我们可以直接打印出 list 的每一个元素,但我们怎么打印出 generator 的 每一个元素呢? 如果要一个一个打印出来,可以通过 next()函数获得 generator 的下一个 StopIteration 我们讲过,generator 保存的是算法,每次调用 next(g),就计算出 g 的 下一个元素的值,直到计算到最后一个元素,没有更多的元素时,抛出 StopIteration 的错误。 当然,上面这种不断调用 next(g)实在是太变态了,正确的方法是使用 for 循环,因为 generator 也是可迭代对象: >>> g = (x * x
    0 码力 | 531 页 | 5.15 MB | 1 年前
    3
  • epub文档 Tornado 6.1 Documentation

    tornado.tcpserver — Basic IOStream-based TCP server Coroutines and concurrency tornado.gen — Generator-based coroutines tornado.locks – Synchronization primitives tornado.queues – Queues for coroutines yield is a generator. All generators are asynchronous; when called they return a generator object instead of running to completion. The @gen.coroutine decorator communicates with the generator via the yield decorator receives a Future from the generator, waits (without blocking) for that Future to complete, then “unwraps” the Future and sends the result back into the generator as the result of the yield expression
    0 码力 | 931 页 | 708.03 KB | 1 年前
    3
  • epub文档 Tornado 6.0 Documentation

    tornado.tcpserver — Basic IOStream-based TCP server Coroutines and concurrency tornado.gen — Generator-based coroutines tornado.locks – Synchronization primitives tornado.queues – Queues for coroutines yield is a generator. All generators are asynchronous; when called they return a generator object instead of running to completion. The @gen.coroutine decorator communicates with the generator via the yield decorator receives a Future from the generator, waits (without blocking) for that Future to complete, then “unwraps” the Future and sends the result back into the generator as the result of the yield expression
    0 码力 | 869 页 | 692.83 KB | 1 年前
    3
  • pdf文档 Python 标准库参考指南 3.6.15

    此行为特性的实现将无法正常使用。 34 Chapter 4. 内置类型 The Python Library Reference, 发布 3.6.15 4.5.1 生成器类型 Python 的generator 提供了一种实现迭代器协议的便捷方式。如果容器对象 __iter__() 方法被实现为一 个生成器,它将自动返回一个迭代器对象(从技术上说是一个生成器对象),该对象提供 __iter__() 和 文件或其他对象的快速关闭,以及更方便地操作活 动的十进制算术上下文。除了实现上下文管理协议以外,不同类型不会被特殊处理。请参阅contextlib 模 块查看相关的示例。 Python 的generator 和contextlib.contextmanager 装饰器提供了实现这些协议的便捷方式。如果 使用contextlib.contextmanager 装饰器来装饰一个生成器函数,它将返回一个实现了必要的 Chapter 5. 内置异常 The Python Library Reference, 发布 3.6.15 exception GeneratorExit 当一个generator 或coroutine 被关闭时将被引发;参见 generator.close() 和 coroutine.close()。 它直接继承自BaseException 而不是Exception,因为从技术上来说它并不是一个错误。
    0 码力 | 1886 页 | 8.95 MB | 9 月前
    3
  • pdf文档 Python 标准库参考指南 3.6.15

    此行为特性的实现将无法正常使用。 34 Chapter 4. 内置类型 The Python Library Reference, 发布 3.6.15 4.5.1 生成器类型 Python 的generator 提供了一种实现迭代器协议的便捷方式。如果容器对象 __iter__() 方法被实现为一 个生成器,它将自动返回一个迭代器对象(从技术上说是一个生成器对象),该对象提供 __iter__() 和 文件或其他对象的快速关闭,以及更方便地操作活 动的十进制算术上下文。除了实现上下文管理协议以外,不同类型不会被特殊处理。请参阅contextlib 模 块查看相关的示例。 Python 的generator 和contextlib.contextmanager 装饰器提供了实现这些协议的便捷方式。如果 使用contextlib.contextmanager 装饰器来装饰一个生成器函数,它将返回一个实现了必要的 Chapter 5. 内置异常 The Python Library Reference, 发布 3.6.15 exception GeneratorExit 当一个generator 或coroutine 被关闭时将被引发;参见 generator.close() 和 coroutine.close()。 它直接继承自BaseException 而不是Exception,因为从技术上来说它并不是一个错误。
    0 码力 | 1886 页 | 8.95 MB | 9 月前
    3
  • pdf文档 Python 标准库参考指南 2.7.18

    . . . . . . . . . . . . . . . . . . . . . . . . 1122 25 开发工具 1123 25.1 pydoc —Documentation generator and online help system . . . . . . . . . . . . . . . . . . . . . . . 1123 25.2 doctest —测试交互性的 a container object’s __iter__() method is implemented as a generator, it will automatically return an iterator object (technically, a generator object) sup- plying the __iter__() and next() methods. More contextlib.contextmanager decorator provide a convenient way to implement these protocols. If a generator function is decorated with the contextlib.contextmanager decorator, it will return a context manager
    0 码力 | 1552 页 | 7.42 MB | 9 月前
    3
  • pdf文档 Python 标准库参考指南 2.7.18

    . . . . . . . . . . . . . . . . . . . . . . . . 1122 25 开发工具 1123 25.1 pydoc —Documentation generator and online help system . . . . . . . . . . . . . . . . . . . . . . . 1123 25.2 doctest —测试交互性的 a container object’s __iter__() method is implemented as a generator, it will automatically return an iterator object (technically, a generator object) sup- plying the __iter__() and next() methods. More contextlib.contextmanager decorator provide a convenient way to implement these protocols. If a generator function is decorated with the contextlib.contextmanager decorator, it will return a context manager
    0 码力 | 1552 页 | 7.42 MB | 9 月前
    3
  • pdf文档 Python 标准库参考指南 2.7.18

    . . . . . . . . . . . . . . . . . . . . . . . . 1122 25 开发工具 1123 25.1 pydoc —Documentation generator and online help system . . . . . . . . . . . . . . . . . . . . . . . 1123 25.2 doctest —测试交互性的 a container object’s __iter__() method is implemented as a generator, it will automatically return an iterator object (technically, a generator object) sup- plying the __iter__() and next() methods. More contextlib.contextmanager decorator provide a convenient way to implement these protocols. If a generator function is decorated with the contextlib.contextmanager decorator, it will return a context manager
    0 码力 | 1552 页 | 7.42 MB | 9 月前
    3
  • pdf文档 Jinja2 Documentation Release 2.10

    the runtime behavior or certain template features. Usually these are security related. 11 code_generator_class The class used for code generation. This should not be changed in most cases, unless you after another and yield piece for piece. This method basically does exactly that and returns a generator that yields one item after another as unicode strings. It accepts the same arguments as render() jinja2.environment.TemplateStream A template stream works pretty much like an ordinary python generator but it can buffer multiple items to reduce the number of total iterations. Per default the 16
    0 码力 | 148 页 | 475.08 KB | 1 年前
    3
  • epub文档 Mypy 1.10.0+dev Documentation

    Callable[[int, float], float] = f def register(callback: Callable[[str], int]) -> None: ... # A generator function that yields ints is secretly just a function that # returns an iterator of ints, so that's class objects [https://peps.python.org/pep-0484/#the-type-of-class-objects]. Generators A basic generator that only yields values can be succinctly annotated as having a return type of either Iterator[YieldType] [https://docs.python.org/3/library/typing.html#typing.Iterable] as the return-type annotation for a generator function, as it lets mypy know that users are able to call next() [https://docs.python.org/3/library/functions
    0 码力 | 318 页 | 270.84 KB | 1 年前
    3
共 308 条
  • 1
  • 2
  • 3
  • 4
  • 5
  • 6
  • 31
前往
页
相关搜索词
Python3基础教程基础教程雪峰Tornado6.1Documentation6.0Python标准参考指南3.6152.718Jinja2Release2.10Mypy1.10dev
IT文库
关于我们 文库协议 联系我们 意见反馈 免责声明
本站文档数据由用户上传或本站整理自互联网,不以营利为目的,供所有人免费下载和学习使用。如侵犯您的权益,请联系我们进行删除。
IT文库 ©1024 - 2025 | 站点地图
Powered By MOREDOC AI v3.3.0-beta.70
  • 关注我们的公众号【刻舟求荐】,给您不一样的精彩
    关注我们的公众号【刻舟求荐】,给您不一样的精彩