[ 
https://issues.apache.org/jira/browse/ARROW-17549?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17597216#comment-17597216
 ] 

Rok Mihevc commented on ARROW-17549:
------------------------------------

This is probably a partial duplicate of ARROW-3802.
The main issue (if I understand correctly) is that we don't have the machinery 
to interpret float16s and we'd need to add it for this functionality (e.g. 
https://sourceforge.net/projects/half/), see ARROW-6436.


> [C++] unsupported cast from halffloat to utf8
> ---------------------------------------------
>
>                 Key: ARROW-17549
>                 URL: https://issues.apache.org/jira/browse/ARROW-17549
>             Project: Apache Arrow
>          Issue Type: Bug
>          Components: C++
>    Affects Versions: 7.0.0
>            Reporter: Joost Hoozemans
>            Priority: Major
>
> Related to https://issues.apache.org/jira/browse/ARROW-17464 but for CSV.
> When writing a table that contains halffloats to CSV:
> {code:python}
> import pyarrow as pa
> import pyarrow.csv as csv
> import numpy as np
> t = pa.table(\{'a': [np.float16(1.0),np.float16(2.0)]}, 
> schema=pa.schema([pa.field("a", pa.float16())]))
> csv.write_csv(t, "out.csv")
> {code}
> Output:
> pyarrow.lib.ArrowNotImplementedError: Unsupported cast from halffloat to utf8 
> using function cast_string



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

Reply via email to