Skip to content
This repository was archived by the owner on Mar 12, 2020. It is now read-only.

Commit

Permalink
Project created for Torch backend
Browse files Browse the repository at this point in the history
  • Loading branch information
Deepak Kumar committed Apr 9, 2019
1 parent 197fab0 commit 1692d2a
Show file tree
Hide file tree
Showing 12 changed files with 557 additions and 28 deletions.
25 changes: 25 additions & 0 deletions Backends/SiaNet.Backend.Torch/NDArrayTensor.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
using SiaNet.Engine;
using System;
using Tensor = SiaNet.Engine.Tensor;

namespace SiaNet.Backend.Torch
{
public class NDArrayTensor : Tensor
{
public NDArrayTensor()
{
K = new SiaNetBackend();
}

public NDArrayTensor(object arr)
{
K = new SiaNetBackend();
}

public override string Name
{
get;
set;
}
}
}
11 changes: 11 additions & 0 deletions Backends/SiaNet.Backend.Torch/SiaNet.Backend.Torch.csproj
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<TargetFramework>netstandard2.0</TargetFramework>
</PropertyGroup>

<ItemGroup>
<ProjectReference Include="..\..\SiaNet.Engine\SiaNet.Engine.csproj" />
</ItemGroup>

</Project>
19 changes: 19 additions & 0 deletions Backends/SiaNet.Backend.Torch/SiaNetActivations.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
using SiaNet.Engine;
using SiaNet.Engine.Layers;
using System;
using System.Collections.Generic;
using System.Text;

namespace SiaNet.Backend.Torch
{
public class SiaNetActivations : ActivationFunc
{
SiaNetBackend backend = null;
public SiaNetActivations(IBackend backend)
: base(backend)
{
backend = K;
}

}
}
Loading

0 comments on commit 1692d2a

Please sign in to comment.