17. Concurrent Execution - Python 3.6.15 documentation 编辑
The modules described in this chapter provide support for concurrent execution of code. The appropriate choice of tool will depend on the task to be executed (CPU bound vs IO bound) and preferred style of development (event driven cooperative multitasking vs preemptive multitasking). Here’s an overview:
- 17.1.
threading
— Thread-based parallelism - 17.2.
multiprocessing
— Process-based parallelism- 17.2.1. Introduction
- 17.2.2. Reference
- 17.2.2.1.
Process
and exceptions - 17.2.2.2. Pipes and Queues
- 17.2.2.3. Miscellaneous
- 17.2.2.4. Connection Objects
- 17.2.2.5. Synchronization primitives
- 17.2.2.6. Shared
ctypes
Objects - 17.2.2.7. Managers
- 17.2.2.8. Proxy Objects
- 17.2.2.9. Process Pools
- 17.2.2.10. Listeners and Clients
- 17.2.2.11. Authentication keys
- 17.2.2.12. Logging
- 17.2.2.13. The
multiprocessing.dummy
module
- 17.2.2.1.
- 17.2.3. Programming guidelines
- 17.2.4. Examples
- 17.3. The
concurrent
package - 17.4.
concurrent.futures
— Launching parallel tasks - 17.5.
subprocess
— Subprocess management - 17.6.
sched
— Event scheduler - 17.7.
queue
— A synchronized queue class
The following are support modules for some of the above services:
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论