b331b9f29062a0e888dafc7a7d19ca8fa53286c1,invesalius/segmentation/brain/utils.py,,get_plaidml_devices,#,1
Before Change
return device
for device in devices:
if b"llvm" in device.description.lower():
return device
After Change
plaidml.settings.experimental = True
devices, _ = plaidml.devices(ctx, limit=100, return_all=True)
out_devices = []
for device in devices:
points = 0
if b"cuda" in device.description.lower():
points += 1
if b"opencl" in device.description.lower():
points += 1
if b"nvidia" in device.description.lower():
points += 1
if b"amd" in device.description.lower():
points += 1
out_devices.append((points, device))
out_devices.sort(reverse=True)
return {device.description.decode("utf8"): device.id.decode("utf8") for points, device in out_devices }
In pattern: SUPERPATTERN
Frequency: 4
Non-data size: 4
Instances
Project Name: invesalius/invesalius3
Commit Name: b331b9f29062a0e888dafc7a7d19ca8fa53286c1
Time: 2020-03-23
Author: totonixsame@gmail.com
File Name: invesalius/segmentation/brain/utils.py
Class Name:
Method Name: get_plaidml_devices
Project Name: GPflow/GPflow
Commit Name: 9cdb2a20cb725f21589beda5fd45b1893b262fe4
Time: 2019-11-21
Author: joehall87@gmail.com
File Name: gpflow/utilities/bijectors.py
Class Name:
Method Name: positive
Project Name: 13o-bbr-bbq/machine_learning_security
Commit Name: 4eb75141ee285b24cdfb0d5a5940da6ee5c59f75
Time: 2018-07-06
Author: takaesu235@gmail.com
File Name: DeepExploit/deep_plugin/classifier_signature/Classifier_signature.py
Class Name: ClassifierSignature
Method Name: identify_product
Project Name: gyoisamurai/GyoiThon
Commit Name: 64fd0c1ea4f3f2fcdc14612e5b4f75689bbf4d22
Time: 2018-11-25
Author: gyoiler3@gmail.com
File Name: modules/Gyoi_CommentChecker.py
Class Name: CommentChecker
Method Name: get_html_comments