Giter Club home page Giter Club logo

tfdroid's Introduction

TFDroid

A simple demo for using Tensorflow models in Android apps

Instructions

You can just clone this repository and open it in Android Studio.

For complete instructions on how to create the Tensorflow model and the app, please look at this blog post: https://omid.al/posts/2017-02-20-Tutorial-Build-Your-First-Tensorflow-Android-App.html.

Feedback, Bugs, and Questions

For any questions, feedback, and bug reports, please use the Github Issues.

Credits

Created by Omid Alemi

Contributions

Contributions are welcome. Please make a pull request.

License

This code is available under the MIT license.

tfdroid's People

Contributors

omimo avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

tfdroid's Issues

Training script for app

Hi!

I am following your tutorial ( https://omid.al/posts/2017-02-20-Tutorial-Build-Your-First-Tensorflow-Android-App.html ).

When I try to generate the .pb file with freeze_graph I get an error.

I have all the required files in the same directory.
Any idea why I am getting this error?

Thanks in advance.

`---------------------------------------------------------------------------
AttributeError Traceback (most recent call last)
in ()
23 filename_tensor_name,
24 output_frozen_graph_name,
---> 25 clear_devices, "")

/home/atig/GitKraken/hallgato-grofattila/Training/freeze_graph.py in freeze_graph(failed resolving arguments)
80
81 # 'input_checkpoint' may be a prefix if we're using Saver V2 format
---> 82 if not saver_lib.checkpoint_exists(input_checkpoint):
83 print("Input checkpoint '" + input_checkpoint + "' doesn't exist!")
84 return -1

AttributeError: module 'tensorflow.python.training.saver' has no attribute 'checkpoint_exists'`

Operation not found

Hi Omimo,
I ran your scripts, but when I execute this statement,
inferenceInterface.fillNodeFloat(INPUT_NODE, INPUT_SIZE, inputFloats);
it is throwing me the following error.
java.lang.IllegalArgumentException: No Operation named [I] in the Graph

using another model with these configuration

omid,

do you think it would be easy to implement another model with your sample?

I surfed the net a lot and found out that there is a variety of ways for using tensorflow model in android,
as I runned your code successfully, I am wondering if using a bit complicated model may work with that also?
It would be best if you could provide this step by step teaching to a more complicated case like this
https://github.com/laviavigdor/twitter-sentiment-analysis

sepas

error with NN part

hey omid,
why when I am running your simple NN code it raises error:
return bytes_or_text.decode(encoding)
UnicodeDecodeError: 'utf-8' codec can't decode byte 0x80 in position 85: invalid start byte

It has problem with last part I mean optimization,
persian girl

Using .tflite file instead of .pb file

Why cant we use .tflite file instead of .pb file in Tensorflow Inference model.
And if I want to use .tflite model than how to implement it with Tensorflow Inference model.

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.