Giter VIP home page Giter VIP logo

iamyourboss / deeprec Goto Github PK

View Code? Open in Web Editor NEW

This project forked from deeprec-ai/deeprec

0.0 1.0 0.0 778.48 MB

DeepRec is a recommendation engine based on TensorFlow.

License: Apache License 2.0

Starlark 2.47% Shell 0.45% Batchfile 0.02% Python 32.93% Dockerfile 0.05% CMake 0.15% Makefile 0.07% HTML 3.16% C++ 55.54% Cuda 0.15% Jupyter Notebook 2.12% C 0.60% MLIR 1.37% SWIG 0.11% Cython 0.01% LLVM 0.01% Java 0.57% Objective-C 0.06% Objective-C++ 0.15% Ruby 0.01%

deeprec's Introduction

Introduction

DeepRec is a recommendation engine based on TensorFlow 1.15, Intel-TensorFlow and NVIDIA-TensorFlow.

Background

Sparse model is a type of deep learning model that accounts for a relatively high proportion of discrete feature calculation logic in the model structure. Discrete features are usually expressed as non-numeric features that cannot be directly processed by algorithms such as id, tag, text, and phrases. They are widely used in high-value businesses such as search, advertising, and recommendation.

DeepRec has been deeply cultivated since 2016, which supports core businesses such as Taobao Search, recommendation and advertising. It precipitates a large number of optimized operators on basic frameworks and has excellent performance in sparse models training.Facing a wide variety of external needs and the environment of deep learning framework embracing open source, deeperec open source is conducive to establishing standardized interfaces, cultivating user habits, greatly reducing the cost of external customers working on cloud and establishing the brand value.

Key Features

DeepRec has super large-scale distributed training capability, supporting model training of trillion samples and 100 billion Embedding Processing. For sparse model scenarios, in-depth performance optimization has ben conducted across CPU and GPU platform. It contains 3 kinds of key features to improve usability and performance for super-scale scenarios.

Sparse Functions

  • Dynamic and elastic embedding processing
  • Embedding elimination and access
  • Dynamic elastic dimension based on embedding frequency
  • Adaptive dynamic elastic embedding

Performance Tuning

  • Distributed Training Framework Optimization, such as grpc+seastar,FuseRecv etc
  • Runtime Optimization
  • Operator level optimization, such as BF16 mixed precision optimizaiton, sparse operator optimizaiton and EmbeddingVariable on PMEM and GPU, new hardware feature enabling, etc.
  • Graph level optimization, such as embedding fusion, Attention and MLP, etc.

Deploy and Serving

  • Incremental model loading and exporting
  • Super-scale sparse model distributed serving
  • Multilevel hybrid storage and multi backend supportcd ..
  • Online deep learning with low latency

Installation

Prepare for installation

CPU Platform

registry.cn-shanghai.aliyuncs.com/pai-dlc/tensorflow-developer:1.15deeprec2106-cpu-py36-ubuntu18.04

GPU Platform

registry.cn-shanghai.aliyuncs.com/pai-dlc/tensorflow-developer:1.15deeprec2106-gpu-py36-cu110-ubuntu18.04

How to Build

configure

$ ./configure

Compile for CPU and GPU defaultly

$ bazel build -c opt --config=opt //tensorflow/tools/pip_package:build_pip_package

Compile for CPU and GPU: ABI=0

$ bazel build --cxxopt="-D_GLIBCXX_USE_CXX11_ABI=0" --host_cxxopt="-D_GLIBCXX_USE_CXX11_ABI=0" -c opt --config=opt //tensorflow/tools/pip_package:build_pip_package

Compile for CPU optimization: oneDNN + Unified Eigen Thread pool

$ bazel build  -c opt --config=opt  --config=mkl_threadpool --define build_with_mkl_dnn_v1_only=true //tensorflow/tools/pip_package:build_pip_package

Compile for CPU optimization and ABI=0

$ bazel build --cxxopt="-D_GLIBCXX_USE_CXX11_ABI=0" --host_cxxopt="-D_GLIBCXX_USE_CXX11_ABI=0" -c opt --config=opt --config=mkl_threadpool --define build_with_mkl_dnn_v1_only=true //tensorflow/tools/pip_package:build_pip_package

Create whl package

$ ./bazel-bin/tensorflow/tools/pip_package/build_pip_package /tmp/tensorflow_pkg

Install whl package

$ pip3 install /tmp/tensorflow_pkg/tensorflow-1.15.5+deeprec2106-cp36-cp36m-linux_x86_64.whl

Nightly Images

Image for GPU CUDA11.0

registry.cn-shanghai.aliyuncs.com/pai-dlc/tensorflow-training:deeprec-nightly-gpu-py36-cu110-ubuntu18.04

Image for CPU

registry.cn-shanghai.aliyuncs.com/pai-dlc/tensorflow-training:deeprec-nightly-cpu-py36-ubuntu18.04

Jave Compilation

$ ./configure
$ bazel build --config opt //tensorflow/java:tensorflow   //tensorflow/java:libtensorflow_jni
$ javac -cp bazel-bin/tensorflow/java/libtensorflow.jar ...
$ java -cp bazel-bin/tensorflow/java/libtensorflow.jar  -Djava.library.path=bazel-bin/tensorflow/java  ...


License

Apache License 2.0

deeprec's People

Contributors

tensorflower-gardener avatar caisq avatar benoitsteiner avatar yongtang avatar gunan avatar mrry avatar martinwicke avatar yifeif avatar hawkinsp avatar alextp avatar ebrevdo avatar allenlavoie avatar annarev avatar asimshankar avatar aaroey avatar ilblackdragon avatar mihaimaruseac avatar markdaoust avatar skye avatar jsimsa avatar terrytangyuan avatar facaiy avatar petewarden avatar nouiz avatar rohan100jain avatar ezhulenev avatar feihugis avatar jdduke avatar andrewharp avatar qlzh727 avatar

Watchers

James Cloos 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.