You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@tika.apache.org by th...@apache.org on 2018/08/14 16:18:39 UTC

[tika] branch master updated: TIKA-2672 -- remove hard coded input dimensions

This is an automated email from the ASF dual-hosted git repository.

thejanw pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/tika.git


The following commit(s) were added to refs/heads/master by this push:
     new 496e156  TIKA-2672 -- remove hard coded input dimensions
496e156 is described below

commit 496e1565421eb9f95399c2e3edf8ba59a58857a8
Author: Thejan Wijesinghe <th...@apache.org>
AuthorDate: Tue Aug 14 21:48:37 2018 +0530

    TIKA-2672 -- remove hard coded input dimensions
---
 .../src/main/java/org/apache/tika/dl/imagerec/DL4JInceptionV3Net.java   | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/tika-dl/src/main/java/org/apache/tika/dl/imagerec/DL4JInceptionV3Net.java b/tika-dl/src/main/java/org/apache/tika/dl/imagerec/DL4JInceptionV3Net.java
index 63ccad8..897d072 100644
--- a/tika-dl/src/main/java/org/apache/tika/dl/imagerec/DL4JInceptionV3Net.java
+++ b/tika-dl/src/main/java/org/apache/tika/dl/imagerec/DL4JInceptionV3Net.java
@@ -260,7 +260,7 @@ public class DL4JInceptionV3Net implements ObjectRecogniser {
 
             KerasModelBuilder builder = new KerasModel().modelBuilder().modelHdf5Filename(modelWeightsPath)
                     .enforceTrainingConfig(false);
-            builder.inputShape(new int[]{299, 299, 3});
+            builder.inputShape(new int[]{imgHeight, imgWidth, 3});
             KerasModel model = builder.buildModel();
             this.graph = model.getComputationGraph();