Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

bigdl 0.12.2 #3780

Merged
merged 4 commits into from
Apr 21, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
<description>simple example of ncf recommender inference</description>
<properties>
<spark.version>2.4.3</spark.version>
<bigdl.version>0.12.1</bigdl.version>
<bigdl.version>0.12.2</bigdl.version>
<zoo.version>0.10.0-SNAPSHOT</zoo.version>
</properties>

Expand Down
2 changes: 1 addition & 1 deletion docker/hyperzoo/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ FROM ubuntu:18.04
MAINTAINER The Analytics-Zoo Authors https://github.com/intel-analytics/analytics-zoo

ARG ANALYTICS_ZOO_VERSION=0.10.0-SNAPSHOT
ARG BIGDL_VERSION=0.12.1
ARG BIGDL_VERSION=0.12.2
ARG SPARK_VERSION=2.4.3
ARG FLINK_VERSION=1.10.0
ARG JDK_VERSION=8u192
Expand Down
2 changes: 1 addition & 1 deletion docker/zoo/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ MAINTAINER The Analytics-Zoo Authors https://github.com/intel-analytics/analytic
WORKDIR /opt/work

ARG ANALYTICS_ZOO_VERSION=0.10.0-SNAPSHOT
ARG BIGDL_VERSION=0.12.1
ARG BIGDL_VERSION=0.12.2
ARG SPARK_VERSION=2.4.3
ARG RUNTIME_SPARK_MASTER=local[4]
ARG RUNTIME_DRIVER_CORES=4
Expand Down
4 changes: 2 additions & 2 deletions docs/docs/DockerUserGuide/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -248,10 +248,10 @@ sudo docker build \

```
sudo docker build \
--build-arg ANALYTICS_ZOO_VERSION=0.7.0 \
--build-arg ANALYTICS_ZOO_VERSION=0.9.0 \
--build-arg BIGDL_VERSION=0.12.1 \
--build-arg SPARK_VERSION=2.4.3 \
--rm -t intelanalytics/analytics-zoo:0.7.0-bigdl_0.10.0-spark_2.4.3 .
--rm -t intelanalytics/analytics-zoo:0.9.0-bigdl_0.12.1-spark_2.4.3 .
```

---
Expand Down
12 changes: 6 additions & 6 deletions docs/docs/release-download.md
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
## **Release 0.10.0 nightly build**

| | BigDL 0.12.1 |
| | BigDL 0.12.2 |
| ------------- | --------- |
| Spark 2.1.1 | [download](https://oss.sonatype.org/content/repositories/snapshots/com/intel/analytics/zoo/analytics-zoo-bigdl_0.12.1-spark_2.1.1/0.10.0-SNAPSHOT/)|
| Spark 2.2.1 | [download](https://oss.sonatype.org/content/repositories/snapshots/com/intel/analytics/zoo/analytics-zoo-bigdl_0.12.1-spark_2.2.1/0.10.0-SNAPSHOT/)|
| Spark 2.3.1 | [download](https://oss.sonatype.org/content/repositories/snapshots/com/intel/analytics/zoo/analytics-zoo-bigdl_0.12.1-spark_2.3.1/0.10.0-SNAPSHOT/)|
| Spark 2.4.3 | [download](https://oss.sonatype.org/content/repositories/snapshots/com/intel/analytics/zoo/analytics-zoo-bigdl_0.12.1-spark_2.4.3/0.10.0-SNAPSHOT/)|
| Spark 3.0.0 | [download](https://oss.sonatype.org/content/repositories/snapshots/com/intel/analytics/zoo/analytics-zoo-bigdl_0.12.1-spark_3.0.0/0.10.0-SNAPSHOT/)|
| Spark 2.1.1 | [download](https://oss.sonatype.org/content/repositories/snapshots/com/intel/analytics/zoo/analytics-zoo-bigdl_0.12.2-spark_2.1.1/0.10.0-SNAPSHOT/)|
| Spark 2.2.1 | [download](https://oss.sonatype.org/content/repositories/snapshots/com/intel/analytics/zoo/analytics-zoo-bigdl_0.12.2-spark_2.2.1/0.10.0-SNAPSHOT/)|
| Spark 2.3.1 | [download](https://oss.sonatype.org/content/repositories/snapshots/com/intel/analytics/zoo/analytics-zoo-bigdl_0.12.2-spark_2.3.1/0.10.0-SNAPSHOT/)|
| Spark 2.4.3 | [download](https://oss.sonatype.org/content/repositories/snapshots/com/intel/analytics/zoo/analytics-zoo-bigdl_0.12.2-spark_2.4.3/0.10.0-SNAPSHOT/)|
| Spark 3.0.0 | [download](https://oss.sonatype.org/content/repositories/snapshots/com/intel/analytics/zoo/analytics-zoo-bigdl_0.12.2-spark_3.0.0/0.10.0-SNAPSHOT/)|

---
## **Release 0.9.0**
Expand Down
12 changes: 6 additions & 6 deletions docs/readthedocs/source/doc/release.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,27 +6,27 @@ cellpadding="10"
>
<tr>
<td></td>
<td>BigDL 0.12.1</td>
<td>BigDL 0.12.2</td>
</tr>
<tr>
<td>Spark 2.1.1 </td>
<td><a href="https://oss.sonatype.org/content/repositories/snapshots/com/intel/analytics/zoo/analytics-zoo-bigdl_0.12.1-spark_2.1.1/0.10.0-SNAPSHOT/">download</a></td>
<td><a href="https://oss.sonatype.org/content/repositories/snapshots/com/intel/analytics/zoo/analytics-zoo-bigdl_0.12.2-spark_2.1.1/0.10.0-SNAPSHOT/">download</a></td>
</tr>
<tr>
<td>Spark 2.2.1 </td>
<td><a href="https://oss.sonatype.org/content/repositories/snapshots/com/intel/analytics/zoo/analytics-zoo-bigdl_0.12.1-spark_2.2.1/0.10.0-SNAPSHOT/">download</a></td>
<td><a href="https://oss.sonatype.org/content/repositories/snapshots/com/intel/analytics/zoo/analytics-zoo-bigdl_0.12.2-spark_2.2.1/0.10.0-SNAPSHOT/">download</a></td>
</tr>
<tr>
<td>Spark 2.3.1 </td>
<td><a href="https://oss.sonatype.org/content/repositories/snapshots/com/intel/analytics/zoo/analytics-zoo-bigdl_0.12.1-spark_2.3.1/0.10.0-SNAPSHOT/">download</a></td>
<td><a href="https://oss.sonatype.org/content/repositories/snapshots/com/intel/analytics/zoo/analytics-zoo-bigdl_0.12.2-spark_2.3.1/0.10.0-SNAPSHOT/">download</a></td>
</tr>
<tr>
<td>Spark 2.4.3 </td>
<td><a href="https://oss.sonatype.org/content/repositories/snapshots/com/intel/analytics/zoo/analytics-zoo-bigdl_0.12.1-spark_2.4.3/0.10.0-SNAPSHOT/">download</a></td>
<td><a href="https://oss.sonatype.org/content/repositories/snapshots/com/intel/analytics/zoo/analytics-zoo-bigdl_0.12.2-spark_2.4.3/0.10.0-SNAPSHOT/">download</a></td>
</tr>
<tr>
<td>Spark 3.0.0 </td>
<td><a href="https://oss.sonatype.org/content/repositories/snapshots/com/intel/analytics/zoo/analytics-zoo-bigdl_0.12.1-spark_3.0.0/0.10.0-SNAPSHOT/">download</a></td>
<td><a href="https://oss.sonatype.org/content/repositories/snapshots/com/intel/analytics/zoo/analytics-zoo-bigdl_0.12.2-spark_3.0.0/0.10.0-SNAPSHOT/">download</a></td>
</tr>
</table>
<br>
Expand Down
2 changes: 1 addition & 1 deletion pyzoo/setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -136,7 +136,7 @@ def setup_package():
license='Apache License, Version 2.0',
url='https://github.com/intel-analytics/analytics-zoo',
packages=packages,
install_requires=['pyspark==2.4.3', 'bigdl==0.12.1', 'conda-pack==0.3.1'],
install_requires=['pyspark==2.4.3', 'bigdl==0.12.2', 'conda-pack==0.3.1'],
extras_require={'ray': ['ray==1.2.0', 'psutil', 'aiohttp==3.7.0',
'setproctitle', 'pyarrow==0.17.0', 'hiredis==1.1.0'],
'automl': ['tensorflow>=1.15.0,<2.0.0', 'h5py==2.10.0', 'hiredis==1.1.0',
Expand Down
50 changes: 1 addition & 49 deletions pyzoo/zoo/common/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
# limitations under the License.
#
from bigdl.util.common import Sample as BSample, JTensor as BJTensor,\
JavaCreator, _get_gateway, _py2java
JavaCreator, _get_gateway, _py2java, _java2py
import numpy as np
import os
import tempfile
Expand Down Expand Up @@ -138,54 +138,6 @@ def callZooFunc(bigdl_type, name, *args):
raise error


# TODO: change to bigdl's _java2py when update to bigdl 0.12.2
def _java2py(gateway, r, encoding="bytes"):
from py4j.protocol import Py4JJavaError
from py4j.java_gateway import JavaObject
from py4j.java_collections import JavaArray, JavaList, JavaMap
from pyspark import RDD
from pyspark.serializers import PickleSerializer
from pyspark.sql import DataFrame
from bigdl.util.common import get_spark_context, _picklable_classes, get_spark_sql_context

if isinstance(r, JavaObject):
clsName = r.getClass().getSimpleName()
# convert RDD into JavaRDD
if clsName != 'JavaRDD' and clsName.endswith("RDD"):
r = r.toJavaRDD()
clsName = 'JavaRDD'

if clsName == 'JavaRDD':
jrdd = gateway.jvm.org.apache.spark.bigdl.api.python.BigDLSerDe.javaToPython(r)
return RDD(jrdd, get_spark_context())

if clsName == 'DataFrame':
return DataFrame(r, get_spark_sql_context(get_spark_context()))

if clsName == 'Dataset':
return DataFrame(r, get_spark_sql_context(get_spark_context()))

if clsName == "ImageFrame[]":
return r

if clsName in _picklable_classes:
r = gateway.jvm.org.apache.spark.bigdl.api.python.BigDLSerDe.dumps(r)
elif isinstance(r, (JavaArray, JavaList)) and len(r) != 0 \
and isinstance(r[0], JavaObject) \
and r[0].getClass().getSimpleName() in ['DataFrame', 'Dataset']:
spark = get_spark_sql_context(get_spark_context())
r = list(map(lambda x: DataFrame(x, spark), r))
elif isinstance(r, (JavaArray, JavaList, JavaMap)):
try:
r = gateway.jvm.org.apache.spark.bigdl.api.python.BigDLSerDe.dumps(
r)
except Py4JJavaError:
pass # not pickable
if isinstance(r, (bytearray, bytes)):
r = PickleSerializer().loads(bytes(r), encoding=encoding)
return r


class JTensor(BJTensor):

def __init__(self, storage, shape, bigdl_type="float", indices=None):
Expand Down
2 changes: 1 addition & 1 deletion zoo/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@
<scala.macros.version>2.1.0</scala.macros.version>
<scalatest.version>3.0.7</scalatest.version>
<spark.version>2.4.3</spark.version>
<bigdl.version>0.12.1</bigdl.version>
<bigdl.version>0.12.2</bigdl.version>
<bigdl.artifactId>bigdl-SPARK_2.4</bigdl.artifactId>
<maven-site-plugin.version>3.4</maven-site-plugin.version>
<wagon-ssh.version>1.0</wagon-ssh.version>
Expand Down