singa-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "ASF subversion and git services (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (SINGA-194) Add a Platform singleton
Date Fri, 01 Jul 2016 09:52:11 GMT

    [ https://issues.apache.org/jira/browse/SINGA-194?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15358722#comment-15358722
] 

ASF subversion and git services commented on SINGA-194:
-------------------------------------------------------

Commit dc013f34fa1c5cb647290ce185b3c2d6e43dcfe0 in incubator-singa's branch refs/heads/dev
from [~flytosky]
[ https://git-wip-us.apache.org/repos/asf?p=incubator-singa.git;h=dc013f3 ]

SINGA-194 Add a Platform singleton

Add the Platform class whose methods are all static.
It includes methods for query hardware GPUs, e.g., num of gpus, memory of each gpu.
It also creats a vector of singa::Device, e.g., CudaGPU.
NOTE:
If multiple CudaGPU devices are created, and they all use CnMemPool,
then they must share the same CnMemPool instance (otherwise there would
be problems in desctructing the CnMemPool).
It is preferred to use Platform to create CudaGPU devices which would
avoid the above problem.

Updated the APIs for Device and DeviceMemPool.
The GetAllocateMem is not accurate (which is larger than actually requested memory size).

NOTE:
The swig would report errors if USE_CUDA is OFF as the CudaGPU is not avaiable.
TODO(wangwei) resolve this problem in later PR for python setup.


> Add a Platform singleton
> ------------------------
>
>                 Key: SINGA-194
>                 URL: https://issues.apache.org/jira/browse/SINGA-194
>             Project: Singa
>          Issue Type: New Feature
>            Reporter: wangwei
>
> The Platform singleton would be used to 
> 1. query hardware devices, e.g., number of GPUs, memory size, driver info.
> 2. create a device
> 3. other global operations that is not thread-safe, and should be done by a singleton,
e.g., create memory pool using CNMeM.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Mime
View raw message