Hi swift-users,
I’m sharing a project I created in academia. DLVM is a modern compiler
infrastructure for deep learning systems, inspired obviously by LLVM and SIL.
DLVM has a linear algebra IR, automatic differentiation, domain-specific
optimizations and a CPU/GPU code generator. NNKit, a stag
Thanks. That’s true, but there are cases (like making BLAS calls) where I have
to nest more than 4 `withUnsafeMutable…` closures. It’s safe by really clumsy.
I just wish there were a cleaner way that looks like the do-notation in Haskell
or for-notation in Scala.
-Richard
> On Dec 16, 2016, at
s to the kernel are passed in by pointers,
IMO using a bunch of `withUnsafe...` clauses would only make it look
unnecessarily clumsy.
-Richard
> On Dec 16, 2016, at 12:41, Joe Groff wrote:
>
>
>> On Dec 15, 2016, at 11:46 PM, Richard Wei via swift-users
>> wrote:
>>
t;>>>
>>>>
>>>>
>>>> On Fri, Dec 16, 2016 at 4:33 PM, Rien via swift-users
>>>> wrote:
>>>> How about using:
>>>>
>>>> UnsafeMutablePointer
>>>>
>>>> ?
>>>>
>>>&g
f].
>>>
>>> Zhaoxin
>>>
>>>
>>>
>>>
>>>
>>>
>>> On Fri, Dec 16, 2016 at 4:33 PM, Rien via swift-users
>>> wrote:
>>> How about using:
>>>
>>> UnsafeMutablePointer
>>&g
> Site: http://balancingrock.nl <http://balancingrock.nl/>
> Blog: http://swiftrien.blogspot.com <http://swiftrien.blogspot.com/>
> Github: http://github.com/Swiftrien <http://github.com/Swiftrien>
> Project: http://swiftfire.nl <http://swiftfire.nl/>
>
>
>
>
> &g
t; Hope above code works.
>
> Zhaoxin
>
> On Fri, Dec 16, 2016 at 3:46 PM, Richard Wei via swift-users
> mailto:swift-users@swift.org>> wrote:
> Hi,
>
> Swift 3.0.2 seems to have broken my code due to mutating self capture. But I
> have to pass inout se
Hi,
Swift 3.0.2 seems to have broken my code due to mutating self capture. But I
have to pass inout self to the closure. Any workaround?
let blockSize = min(512, count)
let blockCount = (count+blockSize-1)/blockSize
device.sync { // Launch CUDA kernel
try! fill<<<(blockSize,
Hi,
Is there a way to build a system module package into a static/dynamic library,
so that a Swift script can link against this library to find the module? Adding
library products to Package.swift doesn’t seem to work.
Thanks,
Richard
___
swift-user