[GitHub] carbondata pull request #2726: [WIP] Float and Byte DataType support

classic Classic list List threaded Threaded
63 messages Options
1234
Reply | Threaded
Open this post in threaded view
|

[GitHub] carbondata pull request #2726: [WIP] Float and Byte DataType support

qiuchenjian-2
GitHub user kunal642 opened a pull request:

    https://github.com/apache/carbondata/pull/2726

    [WIP] Float and Byte DataType support

    Be sure to do all of the following checklist to help us incorporate
    your contribution quickly and easily:
   
     - [ ] Any interfaces changed?
     
     - [ ] Any backward compatibility impacted?
     
     - [ ] Document update required?
   
     - [ ] Testing done
            Please provide details on
            - Whether new unit test cases have been added or why no new tests are required?
            - How it is tested? Please attach test report.
            - Is it a performance related change? Please attach the performance test report.
            - Any additional information to help reviewers in testing this change.
           
     - [ ] For large changes, please consider breaking it into sub-tasks under an umbrella JIRA.
   


You can merge this pull request into a Git repository by running:

    $ git pull https://github.com/kunal642/carbondata float_support

Alternatively you can review and apply these changes as the patch at:

    https://github.com/apache/carbondata/pull/2726.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

    This closes #2726
   
----
commit aca611a18070b1db61e66e011fc7064848d1f083
Author: kunal642 <kunalkapoor642@...>
Date:   2018-09-14T09:56:10Z

    added support for float data type

commit a4c976f77f2c40f334236b49e3949f66ea38c4e3
Author: kunal642 <kunalkapoor642@...>
Date:   2018-09-16T22:52:55Z

    addede support for byte type

----


---
Reply | Threaded
Open this post in threaded view
|

[GitHub] carbondata issue #2726: [WIP] Float and Byte DataType support

qiuchenjian-2
Github user CarbonDataQA commented on the issue:

    https://github.com/apache/carbondata/pull/2726
 
    Build Failed  with Spark 2.3.1, Please check CI http://136.243.101.176:8080/job/carbondataprbuilder2.3/8542/



---
Reply | Threaded
Open this post in threaded view
|

[GitHub] carbondata issue #2726: [WIP] Float and Byte DataType support

qiuchenjian-2
In reply to this post by qiuchenjian-2
Github user CarbonDataQA commented on the issue:

    https://github.com/apache/carbondata/pull/2726
 
    Build Failed with Spark 2.2.1, Please check CI http://95.216.28.178:8080/job/ApacheCarbonPRBuilder1/472/



---
Reply | Threaded
Open this post in threaded view
|

[GitHub] carbondata issue #2726: [WIP] Float and Byte DataType support

qiuchenjian-2
In reply to this post by qiuchenjian-2
Github user CarbonDataQA commented on the issue:

    https://github.com/apache/carbondata/pull/2726
 
    Build Failed  with Spark 2.1.0, Please check CI http://136.243.101.176:8080/job/ApacheCarbonPRBuilder2.1/297/



---
Reply | Threaded
Open this post in threaded view
|

[GitHub] carbondata issue #2726: [WIP] Float and Byte DataType support

qiuchenjian-2
In reply to this post by qiuchenjian-2
Github user CarbonDataQA commented on the issue:

    https://github.com/apache/carbondata/pull/2726
 
    Build Success with Spark 2.1.0, Please check CI http://136.243.101.176:8080/job/ApacheCarbonPRBuilder2.1/301/



---
Reply | Threaded
Open this post in threaded view
|

[GitHub] carbondata issue #2726: [WIP] Float and Byte DataType support

qiuchenjian-2
In reply to this post by qiuchenjian-2
Github user CarbonDataQA commented on the issue:

    https://github.com/apache/carbondata/pull/2726
 
    Build Success with Spark 2.3.1, Please check CI http://136.243.101.176:8080/job/carbondataprbuilder2.3/8546/



---
Reply | Threaded
Open this post in threaded view
|

[GitHub] carbondata issue #2726: [WIP] Float and Byte DataType support

qiuchenjian-2
In reply to this post by qiuchenjian-2
Github user CarbonDataQA commented on the issue:

    https://github.com/apache/carbondata/pull/2726
 
    Build Success with Spark 2.2.1, Please check CI http://95.216.28.178:8080/job/ApacheCarbonPRBuilder1/476/



---
Reply | Threaded
Open this post in threaded view
|

[GitHub] carbondata pull request #2726: [WIP] Float and Byte DataType support

qiuchenjian-2
In reply to this post by qiuchenjian-2
Github user ravipesala commented on a diff in the pull request:

    https://github.com/apache/carbondata/pull/2726#discussion_r218104702
 
    --- Diff: core/src/main/java/org/apache/carbondata/core/datastore/page/LazyColumnPage.java ---
    @@ -93,7 +93,22 @@ public double getDouble(int rowId) {
     
       @Override
       public float getFloat(int rowId) {
    -    throw new UnsupportedOperationException("internal error");
    +    DataType dataType = columnPage.getDataType();
    --- End diff --
   
    Just call `getDouble(rowId)` from this method and then typecast it. No need to duplicate the code


---
Reply | Threaded
Open this post in threaded view
|

[GitHub] carbondata pull request #2726: [WIP] Float and Byte DataType support

qiuchenjian-2
In reply to this post by qiuchenjian-2
Github user ravipesala commented on a diff in the pull request:

    https://github.com/apache/carbondata/pull/2726#discussion_r218108240
 
    --- Diff: core/src/main/java/org/apache/carbondata/core/datastore/page/encoding/ColumnPageEncoderMeta.java ---
    @@ -132,6 +132,10 @@ private void writeMinMax(DataOutput out) throws IOException {
           out.writeDouble((Double) getMaxValue());
           out.writeDouble((Double) getMinValue());
           out.writeDouble(0d); // unique value is obsoleted, maintain for compatibility
    +    } else if (dataType == DataTypes.FLOAT) {
    +      out.writeDouble((Float) getMaxValue());
    --- End diff --
   
    Why not written in Float? Please written in float instead of double


---
Reply | Threaded
Open this post in threaded view
|

[GitHub] carbondata pull request #2726: [WIP] Float and Byte DataType support

qiuchenjian-2
In reply to this post by qiuchenjian-2
Github user ravipesala commented on a diff in the pull request:

    https://github.com/apache/carbondata/pull/2726#discussion_r218109409
 
    --- Diff: core/src/main/java/org/apache/carbondata/core/datastore/page/encoding/adaptive/AdaptiveFloatingCodec.java ---
    @@ -139,15 +139,15 @@ public void encode(int rowId, long value) {
         @Override
         public void encode(int rowId, float value) {
           if (targetDataType == DataTypes.BYTE) {
    -        encodedPage.putByte(rowId, (byte) (value * factor));
    +        encodedPage.putByte(rowId, (byte) (value * (float) factor));
    --- End diff --
   
    don't typecast it every time, take another float variable at class level


---
Reply | Threaded
Open this post in threaded view
|

[GitHub] carbondata pull request #2726: [WIP] Float and Byte DataType support

qiuchenjian-2
In reply to this post by qiuchenjian-2
Github user ravipesala commented on a diff in the pull request:

    https://github.com/apache/carbondata/pull/2726#discussion_r218110451
 
    --- Diff: core/src/main/java/org/apache/carbondata/core/datastore/page/statistics/PrimitivePageStatsCollector.java ---
    @@ -140,6 +149,10 @@ private PrimitivePageStatsCollector(DataType dataType) {
           minDouble = Double.POSITIVE_INFINITY;
           maxDouble = Double.NEGATIVE_INFINITY;
           decimal = 0;
    +    } else if (dataType == DataTypes.FLOAT) {
    +      minFloat = Float.MIN_VALUE;
    --- End diff --
   
    It should be reverse, please check other datatypes. minFloat should be Float.MAX_VALUE


---
Reply | Threaded
Open this post in threaded view
|

[GitHub] carbondata issue #2726: [WIP] Float and Byte DataType support

qiuchenjian-2
In reply to this post by qiuchenjian-2
Github user CarbonDataQA commented on the issue:

    https://github.com/apache/carbondata/pull/2726
 
    Build Success with Spark 2.1.0, Please check CI http://136.243.101.176:8080/job/ApacheCarbonPRBuilder2.1/321/



---
Reply | Threaded
Open this post in threaded view
|

[GitHub] carbondata issue #2726: [WIP] Float and Byte DataType support

qiuchenjian-2
In reply to this post by qiuchenjian-2
Github user CarbonDataQA commented on the issue:

    https://github.com/apache/carbondata/pull/2726
 
    Build Failed  with Spark 2.3.1, Please check CI http://136.243.101.176:8080/job/carbondataprbuilder2.3/8567/



---
Reply | Threaded
Open this post in threaded view
|

[GitHub] carbondata issue #2726: [WIP] Float and Byte DataType support

qiuchenjian-2
In reply to this post by qiuchenjian-2
Github user CarbonDataQA commented on the issue:

    https://github.com/apache/carbondata/pull/2726
 
    Build Failed with Spark 2.2.1, Please check CI http://95.216.28.178:8080/job/ApacheCarbonPRBuilder1/497/



---
Reply | Threaded
Open this post in threaded view
|

[GitHub] carbondata issue #2726: [WIP] Float and Byte DataType support

qiuchenjian-2
In reply to this post by qiuchenjian-2
Github user CarbonDataQA commented on the issue:

    https://github.com/apache/carbondata/pull/2726
 
    Build Failed  with Spark 2.3.1, Please check CI http://136.243.101.176:8080/job/carbondataprbuilder2.3/8571/



---
Reply | Threaded
Open this post in threaded view
|

[GitHub] carbondata issue #2726: [WIP] Float and Byte DataType support

qiuchenjian-2
In reply to this post by qiuchenjian-2
Github user CarbonDataQA commented on the issue:

    https://github.com/apache/carbondata/pull/2726
 
    Build Failed with Spark 2.2.1, Please check CI http://95.216.28.178:8080/job/ApacheCarbonPRBuilder1/501/



---
Reply | Threaded
Open this post in threaded view
|

[GitHub] carbondata issue #2726: [WIP] Float and Byte DataType support

qiuchenjian-2
In reply to this post by qiuchenjian-2
Github user CarbonDataQA commented on the issue:

    https://github.com/apache/carbondata/pull/2726
 
    Build Failed  with Spark 2.1.0, Please check CI http://136.243.101.176:8080/job/ApacheCarbonPRBuilder2.1/325/



---
Reply | Threaded
Open this post in threaded view
|

[GitHub] carbondata issue #2726: [WIP] Float and Byte DataType support

qiuchenjian-2
In reply to this post by qiuchenjian-2
Github user CarbonDataQA commented on the issue:

    https://github.com/apache/carbondata/pull/2726
 
    Build Success with Spark 2.1.0, Please check CI http://136.243.101.176:8080/job/ApacheCarbonPRBuilder2.1/326/



---
Reply | Threaded
Open this post in threaded view
|

[GitHub] carbondata issue #2726: [WIP] Float and Byte DataType support

qiuchenjian-2
In reply to this post by qiuchenjian-2
Github user CarbonDataQA commented on the issue:

    https://github.com/apache/carbondata/pull/2726
 
    Build Failed  with Spark 2.3.1, Please check CI http://136.243.101.176:8080/job/carbondataprbuilder2.3/8572/



---
Reply | Threaded
Open this post in threaded view
|

[GitHub] carbondata issue #2726: [WIP] Float and Byte DataType support

qiuchenjian-2
In reply to this post by qiuchenjian-2
Github user CarbonDataQA commented on the issue:

    https://github.com/apache/carbondata/pull/2726
 
    Build Failed with Spark 2.2.1, Please check CI http://95.216.28.178:8080/job/ApacheCarbonPRBuilder1/502/



---
1234