Tornado 6.5 DocumentationFutures in parallel: from tornado.gen import multi async def parallel_fetch(url1, url2): resp1, resp2 = await multi([http_client.fetch(url1), http_client.fetch(url2)]) async def parallel_fetch_many(urls): fetch(url) for url in urls]) # responses is a list of HTTPResponses in the same order async def parallel_fetch_dict(urls): responses = await multi({url: http_client.fetch(url) for url in urls}) # responses In decorated coroutines, it is possible to yield the list or dict directly: @gen.coroutine def parallel_fetch_decorated(url1, url2): resp1, resp2 = yield [http_client.fetch(url1), http_client.fetch(url2)]0 码力 | 272 页 | 1.12 MB | 3 月前3
Tornado 6.5 Documentationdicts whose values are Futures, and waits for all of those Futures in parallel: from tornado.gen import multi async def parallel_fetch(url1, url2): resp1, resp2 = await multi([http_client.fetch(url1) async def parallel_fetch_many(urls): responses = await multi ([http_client.fetch(url) for url in urls]) # responses is a list of HTTPResponses in the same order async def parallel_fetch_dict(urls): In decorated coroutines, it is possible to yield the list or dict directly: @gen.coroutine def parallel_fetch_decorated(url1, url2): resp1, resp2 = yield [http_client.fetch(url1),0 码力 | 437 页 | 405.14 KB | 3 月前3
Trends Artificial Intelligence
Models Led To… *A FLOP (floating point operation) is a basic unit of computation used to measure processing power, representing a single arithmetic calculation involving decimal numbers. In AI, total FLOPs on some reasoning tests 3/23: OpenAI releases GPT-4, a multimodal* model capable of processing both text & images 3/23: Google releases Bard, its ChatGPT competitor 11/23: 28 countries designate particularly influential models within the AI/machine learning ecosystem. Epoch maintains a database of 900 AI models released since the 1950s, selecting entries based on criteria such as state-of-the-art0 码力 | 340 页 | 12.14 MB | 5 月前3
Julia 1.11.4Multicast . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 308 23 Parallel Computing 310 24 Asynchronous Programming 311 24.1 Basic Task operations . . . . . . . . . . of Finalizers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 327 26 Multi-processing and Distributed Computing 329 26.1 Code Availability and Loading Packages . . . . . . . . . . Global variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 335 26.5 Parallel Map and Loops . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 336 26.6 Remote0 码力 | 2007 页 | 6.73 MB | 3 月前3
Julia 1.11.5 DocumentationMulticast . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 308 23 Parallel Computing 310 24 Asynchronous Programming 311 24.1 Basic Task operations . . . . . . . . . . of Finalizers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 327 26 Multi-processing and Distributed Computing 329 26.1 Code Availability and Loading Packages . . . . . . . . . . Global variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 335 26.5 Parallel Map and Loops . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 336 26.6 Remote0 码力 | 2007 页 | 6.73 MB | 3 月前3
Julia 1.11.6 Release NotesMulticast . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 308 23 Parallel Computing 310 24 Asynchronous Programming 311 24.1 Basic Task operations . . . . . . . . . . of Finalizers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 327 26 Multi-processing and Distributed Computing 329 26.1 Code Availability and Loading Packages . . . . . . . . . . Global variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 335 26.5 Parallel Map and Loops . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 336 26.6 Remote0 码力 | 2007 页 | 6.73 MB | 3 月前3
Julia 1.12.0 RC1Multicast . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 311 23 Parallel Computing 313 24 Asynchronous Programming 314 24.1 Basic Task operations . . . . . . . . . . of Finalizers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 331 26 Multi-processing and Distributed Computing 333 26.1 Code Availability and Loading Packages . . . . . . . . . . Global variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 339 26.5 Parallel Map and Loops . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 340 26.6 Remote0 码力 | 2057 页 | 7.44 MB | 3 月前3
Julia 1.12.0 Beta4Multicast . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 311 23 Parallel Computing 313 24 Asynchronous Programming 314 24.1 Basic Task operations . . . . . . . . . . of Finalizers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 331 26 Multi-processing and Distributed Computing 332 26.1 Code Availability and Loading Packages . . . . . . . . . . Global variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 338 26.5 Parallel Map and Loops . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 339 26.6 Remote0 码力 | 2057 页 | 7.44 MB | 3 月前3
Julia 1.12.0 Beta3Multicast . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 311 23 Parallel Computing 313 24 Asynchronous Programming 314 24.1 Basic Task operations . . . . . . . . . . of Finalizers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 331 26 Multi-processing and Distributed Computing 332 26.1 Code Availability and Loading Packages . . . . . . . . . . Global variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 338 26.5 Parallel Map and Loops . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 339 26.6 Remote0 码力 | 2057 页 | 7.44 MB | 3 月前3
julia 1.12.0 beta1Multicast . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 311 23 Parallel Computing 313 24 Asynchronous Programming 314 24.1 Basic Task operations . . . . . . . . . . of Finalizers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 331 26 Multi-processing and Distributed Computing 332 26.1 Code Availability and Loading Packages . . . . . . . . . . Global variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 338 26.5 Parallel Map and Loops . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 339 26.6 Remote0 码力 | 2047 页 | 7.41 MB | 3 月前3
共 15 条
- 1
- 2













