945a842a75ed76c6823b1bc5e58c8db44d13f208,example2.py,,,#,18

Before Change



    // encoding without blocking:
    print("sending all data without blocking...")
    for _ in range(10):
        bc.encode(data, blocking=False)
    print("done!")
    num_expect_vecs = len(data) * 10

    // then fetch all

After Change


    // this time fetch them one by one, due to the async encoding and server scheduling
    // sending order is NOT preserved!
    for v in bc.fetch():
        print("received %s, shape %s" % (v.id, v.content.shape))

    // get encoded vectors
    for j in bc.encode_async(text_gen(), max_num_batch=20):
        print("received %d : %s" % (j.id, j.content))
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 4

Non-data size: 4

Instances


Project Name: hanxiao/bert-as-service
Commit Name: 945a842a75ed76c6823b1bc5e58c8db44d13f208
Time: 2018-12-04
Author: hanhxiao@tencent.com
File Name: example2.py
Class Name:
Method Name:


Project Name: ray-project/ray
Commit Name: 244aafdcf89ae814975c8c4e3faf0bd4995c7878
Time: 2020-09-05
Author: sven@anyscale.io
File Name: rllib/utils/exploration/tests/test_curiosity.py
Class Name: OneHotWrapper
Method Name: observation


Project Name: streamlit/streamlit
Commit Name: c08378840b012c9f8d4883fcd08e64c6fd3e2dfa
Time: 2018-03-18
Author: adrien.g.treuille@gmail.com
File Name: examples/new.py
Class Name:
Method Name:


Project Name: streamlit/streamlit
Commit Name: fde7186089811bfc1e8b13600027d63979678e3a
Time: 2018-03-10
Author: adrien.g.treuille@gmail.com
File Name: examples/new.py
Class Name:
Method Name: