Skip to content

TensorFlowTransformer is not properly matching the input dimensions #2458

Closed
@LucasFievet

Description

@LucasFievet

System information

  • OS version/distro: Windows 10/Pro
  • .NET Version (eg., dotnet --info): .NET Version 2.1.202
  • ML.TensorFlow Version 0.10

Issue

  • What did you do?: Executed a TensorFlow model using TensorFlowEstimator
  • What happened?: Mapper does not properly match the input dimensions to the TensorFlow model dimensions
  • What did you expect?: Properly matched dimensions

Source code / logs

TensorFlowTransform.cs, Lines 810 - 875

Line 853:

var d = originalShape.NumDimensions > 2 ? Math.Pow(typeValueCount / valCount, 1.0 / (originalShape.NumDimensions - 2)) : 1;

The case with 2 dimensions, where the originalShape is [1, ?] is not matched properly.

Activity

Ivanidzo4ka

Ivanidzo4ka commented on Feb 7, 2019

@Ivanidzo4ka
Contributor

@yaeldekel

var d = originalShape.NumDimensions > 2 ? Math.Pow(typeValueCount / valCount, 1.0 / (originalShape.NumDimensions - 2)) : 1;

do you know why we setting variable length only for tensors with size more than 2?
@zeahmed do we have tests with variable length? If yes, I believe it's probably for images, can we have test for two dimensional model?

zeahmed

zeahmed commented on Feb 7, 2019

@zeahmed
Contributor

No, this is the bug and I am going to make a fix for it.

self-assigned this
on Feb 7, 2019
ghost locked as resolved and limited conversation to collaborators on Mar 24, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

bugSomething isn't working

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

    Participants

    @Ivanidzo4ka@LucasFievet@zeahmed

    Issue actions

      TensorFlowTransformer is not properly matching the input dimensions · Issue #2458 · dotnet/machinelearning