Coder Social home page Coder Social logo

Comments (13)

Oceania2018 avatar Oceania2018 commented on August 21, 2024 2

We could reactive the KerasSharp, wrap the TorchSharp and TensorFlow.NET or TensorFlowSharp, ML.NET and CNTK.

from torchsharp.

interesaaat avatar interesaaat commented on August 21, 2024 1

I personally believe that we should stay closer to C# conventions instead of exactly mirroring the python API. The goal of the project is in fact to provide a way for C# users to run and build deep learning models through PyTorch, and not the other way around (i.e., PyTorch users that want to use C# instead of python). For instance I have several problems with this:

  • C# is typed, are we sure we still want to hide types to TorchSharp users?
  • C# users may find the Python-ish API weird to use
  • Since we are mapping to C++ object we will have to surface some C# stuff anyway (e.g., object disposal)

from torchsharp.

deepakkumar1984 avatar deepakkumar1984 commented on August 21, 2024 1

A similar project like keras sharp with multiple backends. I can try to include torchsharp soon.
https://github.com/deepakkumar1984/SiaNet/

from torchsharp.

JeroMiya avatar JeroMiya commented on August 21, 2024 1

This seems to be a recurring issue with libraries ported from other languages to .NET - what naming convention to use for the API?

There are two schools of thought:

  1. Keep close to the original library's naming conventions, even if they conflict with the .NET naming conventions, to make it easier to port code from samples and documentation into the new .NET library.
  2. Use the .NET naming conventions, making the library easier to use for .NET developers. These naming conventions convey information (e.g. property vs function vs field etc...) and when they are not followed code can become more difficult to read.

Both of these schools of thought are equally valid, but of course they conflict with each other. I think school of thought 1 is best for the early stages of the library, getting started, etc... but I think long term 2 is the best. Supporting both in parallel would be ideal though. It would be nice if there were some automated way to generate a .NET convention version of the API surface in parallel to the Python-style API.

As an aside, it's interesting to me that F# uses a naming convention more like Python (for historical reasons, given F# is based on the ML family of languages), but only for private methods within an implementation and for the F# standard library. Even for F# facing libraries written in F#, the recommended conventions for public facing APIs is to use the .NET convention, though that seems to be inconsistently followed in the wild.

from torchsharp.

dsyme avatar dsyme commented on August 21, 2024 1

Just to note that if I was starting this repo from scratch, I would make it part of SciSharp, and follow SciSharp's naming conventions (i.e. use PyTorch Python naming conventions)

But for now we will stick to the naming conventions we have here

from torchsharp.

interesaaat avatar interesaaat commented on August 21, 2024

This could be a good option! I also like the idea of using Keras API on top of ML.NET (how does that work?)

from torchsharp.

Oceania2018 avatar Oceania2018 commented on August 21, 2024

@interesaaat The author of KerasSharp doesn't response cesarsouza/keras-sharp#29 .

from torchsharp.

Oceania2018 avatar Oceania2018 commented on August 21, 2024

@deepakkumar1984 Could you add TensorFlow.NET as a backend?

from torchsharp.

deepakkumar1984 avatar deepakkumar1984 commented on August 21, 2024

from torchsharp.

Oceania2018 avatar Oceania2018 commented on August 21, 2024

Refer this thread, you will know how valuable it is. The most important is TensorFlow.NET can Build Graph -> Train -> Inference model in one library. @deepakkumar1984

from torchsharp.

deepakkumar1984 avatar deepakkumar1984 commented on August 21, 2024

from torchsharp.

Oceania2018 avatar Oceania2018 commented on August 21, 2024

Sure, cross-platform, run in CUDA.

from torchsharp.

dsyme avatar dsyme commented on August 21, 2024

I'm closing this as it's covered by #95

from torchsharp.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.