Git Product home page Git Product logo

cpp_torch's Introduction

header only, deep learning framework with no dependencies other than libtorch


The current code works with libtorch1.3, but the latest is libtorch1.4.

Support for libtorch1.3 to libtorch1.4 is being promoted. Please wait. The current changes that we learned from the work It cannot be compiled with visual studio2015. visual studio2017 also requires updates to the latest patches.

with_bias-> bias transposed seems to be abolished in torch :: nn :: Conv2dOptions. Instead Must be changed to torch :: nn :: ConvTranspose2d. torch :: nn :: FeatureDropout also seems to be abolished. instead of Use torch :: nn :: Dropout2d.

Other torch :: Tensor & tensor = torch :: tensor ({vec [i]}); Is said to be a tensor and terminates abnormally. torch :: Tensor & tensor = torch :: tensor (vec [i]); Must be.

(/std:c++17) std::byte compile error C2872 compile option -> /D _HAS_STD_BYTE=0


Directory structure

This project aims to be a wrapper for libtorch to make tiny-dnn compatible with GPU. tiny-dnn really great, but unfortunately it can not be calculated on a GPU. At first glance, this header-only framework aims to be used as written in tiny-dnn.

Include path settings

Libtorch_path/include
Libtorch_path/include/torch/csrc/api/include
cpp_torch_path
cpp_torch_path/include

Library path setting

Libtorch_path/lib
cpp_torch_path

Minimum include file

#include "cpp_torch.h"

progress
tiny_dnn

tiny_dnn::progress_display disp(train_images.size());

cpp_torch

cpp_torch::progress_display disp(train_images.size());

cpp_torch::progress_display disp(train_images.size());

data set download
What you can do is still limited.

config.h

options description default
USE_WINDOWS ON
USE_COLOR_CONSOLE ON
USE_ZLIB ON
USE_IMAGE_UTIL ON
USE_OPENCV_UTIL OpenCV >= 2.3 OFF ex. C:\dev\opencv-3.4.0

example

MNIS
CIFAR10
DCGAN

Latest topic

Do you have a favorite cute person?

This app was created with C # for GUI and C ++ only for core processing. Python is not required.

This application is in cpp_torch/example/app/dcgan_Application

Requirements

visual studio 2015,2017,2019

libtorch Please adapt the version of cuda to your environment

tiny-dnn

BSD 3-Clause License Copyright (c) 2013, Taiga Nomi

tiny_dnn was good, but unfortunately development has clearly stopped. Therefore, we created cpp_torch that can be used instead.

If you are building in C++,
Even if Python or pytorch (libtorch) is changed Should work.  

Will the Python app function correctly next month?  
Is there a guarantee that customers will not update python, etc.?

cpp_torch's People

Contributors

sanaxen avatar

Watchers

 avatar

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.