Skip to content

Commit

Permalink
Merge pull request #11 from am15h/v0.1.0
Browse files Browse the repository at this point in the history
release v0.1.0
  • Loading branch information
am15h authored Jul 1, 2020
2 parents ecf77c6 + 237d4cd commit faf6d51
Show file tree
Hide file tree
Showing 12 changed files with 17 additions and 25 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/flutter_drive.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ jobs:
java-version: '8.x'
- uses: subosito/flutter-action@v1
with:
flutter-version: '1.12.13+hotfix.5'
flutter-version: '1.17.4'
channel: 'stable'
- name: run tests
timeout-minutes: 30
Expand All @@ -37,4 +37,4 @@ jobs:
profile: ${{ matrix.device }}
script: |
cd ./example/image_classification && flutter pub get
cd ./example/image_classification && flutter driver --driver='test_driver/image_classification_e2e_test.dart' test/image_classification_e2e.dart
cd ./example/image_classification && flutter driver --driver='test_driver/image_classification_e2e_test.dart' test/image_classification_e2e.dart
2 changes: 1 addition & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
# The .vscode folder contains launch configuration and tasks you configure in
# VS Code which you may wish to be included in version control, so this line
# is commented out by default.
#.vscode/
.vscode/

# Flutter/Dart/Pub related
**/doc/api/
Expand Down
2 changes: 1 addition & 1 deletion example/image_classification/lib/classifier_quant.dart
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import 'package:imageclassification/classifier.dart';
import 'package:tflite_flutter_helper/src/common/ops/normailze_op.dart';
import 'package:tflite_flutter_helper/tflite_flutter_helper.dart';

class ClassifierQuant extends Classifier {
ClassifierQuant({int numThreads: 1}) : super(numThreads: numThreads);
Expand Down
5 changes: 0 additions & 5 deletions example/image_classification/test/widget_test.dart
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,4 @@
// gestures. You can also use WidgetTester to find child widgets in the widget
// tree, read text, and verify that the values of widget properties are correct.

import 'package:flutter/material.dart';
import 'package:flutter_test/flutter_test.dart';

import 'package:imageclassification/main.dart';

void main() {}
5 changes: 5 additions & 0 deletions example/pubspec.lock
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
# Generated by pub
# See https://dart.dev/tools/pub/glossary#lockfile
packages: {}
sdks:
dart: ">=2.1.0 <3.0.0"
1 change: 0 additions & 1 deletion lib/src/common/ops/normailze_op.dart
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@ import 'package:tflite_flutter/tflite_flutter.dart';
import 'package:tflite_flutter_helper/src/common/support_preconditions.dart';
import 'package:tflite_flutter_helper/src/common/tensor_operator.dart';
import 'package:tflite_flutter_helper/src/tensorbuffer/tensorbuffer.dart';
import 'package:tflite_flutter_helper/src/tensorbuffer/tensorbufferfloat.dart';

/// Normalizes a [TensorBuffer] with given mean and stddev: output = (input - mean) / stddev.
class NormalizeOp implements TensorOperator {
Expand Down
1 change: 0 additions & 1 deletion lib/src/common/tensor_operator.dart
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
import 'package:tflite_flutter_helper/src/common/operator.dart';
import 'package:tflite_flutter_helper/src/common/sequential_processor.dart';
import 'package:tflite_flutter_helper/src/tensorbuffer/tensorbuffer.dart';

/// Applies some operation on TensorBuffers.
Expand Down
2 changes: 0 additions & 2 deletions lib/src/image/image_conversions.dart
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
import 'dart:io';

import 'package:image/image.dart';
import 'package:tflite_flutter/tflite_flutter.dart';
import 'package:tflite_flutter_helper/src/image/tensor_image.dart';
Expand Down
5 changes: 1 addition & 4 deletions lib/src/tensorbuffer/tensorbufferfloat.dart
Original file line number Diff line number Diff line change
@@ -1,14 +1,11 @@
import 'dart:typed_data';

import 'package:tflite_flutter/src/bindings/types.dart';
import 'package:tflite_flutter/tflite_flutter.dart';
import 'package:tflite_flutter_helper/src/common/support_preconditions.dart';

import 'tensorbuffer.dart';

/// Represents data buffer with float(double) values.
class TensorBufferFloat extends TensorBuffer {
static final TfLiteType DATA_TYPE = TfLiteType.float32;
static const TfLiteType DATA_TYPE = TfLiteType.float32;

/// Creates a [TensorBufferFloat] with specified [shape].
///
Expand Down
2 changes: 0 additions & 2 deletions lib/src/tensorbuffer/tensorbufferuint8.dart
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
import 'dart:ffi';
import 'dart:typed_data';
import 'dart:math';

import 'package:tflite_flutter/tflite_flutter.dart';
Expand Down
4 changes: 2 additions & 2 deletions pubspec.lock
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,7 @@ packages:
source: hosted
version: "0.12.6"
meta:
dependency: transitive
dependency: "direct main"
description:
name: meta
url: "https://pub.dartlang.org"
Expand Down Expand Up @@ -173,7 +173,7 @@ packages:
source: hosted
version: "3.0.13"
quiver:
dependency: transitive
dependency: "direct main"
description:
name: quiver
url: "https://pub.dartlang.org"
Expand Down
9 changes: 5 additions & 4 deletions pubspec.yaml
Original file line number Diff line number Diff line change
@@ -1,17 +1,18 @@
name: tflite_flutter_helper
description: Easy processing and manipulating input and output of TensorFlow Lite Models.
description: Easy, fast processing and manipulation input and output of TensorFlow Lite Models.
version: 0.1.0
author: Amish Garg
homepage:
homepage: https://www.github.com/am15h/tflite_flutter_helper

environment:
sdk: ">=2.6.0 <3.0.0"

dependencies:
flutter:
sdk: flutter
meta: ^1.1.8
quiver: ^2.1.3

path_provider:
path_provider: ^1.6.11
tflite_flutter: ^0.4.1
image: ^2.1.4

Expand Down

0 comments on commit faf6d51

Please sign in to comment.