Skip to content

Commit

Permalink
Merge branch 'branch-0.20' into enh-dateoffset-more-units
Browse files Browse the repository at this point in the history
  • Loading branch information
brandon-b-miller authored Apr 19, 2021
2 parents b4eefa0 + b8baed5 commit e0f1b5c
Show file tree
Hide file tree
Showing 158 changed files with 1,581 additions and 1,578 deletions.
12 changes: 6 additions & 6 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -160,7 +160,7 @@ git submodule update --init --remote --recursive
```bash
# create the conda environment (assuming in base `cudf` directory)
# note: RAPIDS currently doesn't support `channel_priority: strict`; use `channel_priority: flexible` instead
conda env create --name cudf_dev --file conda/environments/cudf_dev_cuda10.0.yml
conda env create --name cudf_dev --file conda/environments/cudf_dev_cuda11.0.yml
# activate the environment
conda activate cudf_dev
```
Expand Down Expand Up @@ -281,8 +281,8 @@ A Dockerfile is provided with a preconfigured conda environment for building and
### Prerequisites

* Install [nvidia-docker2](https://github.com/nvidia/nvidia-docker/wiki/Installation-(version-2.0)) for Docker + GPU support
* Verify NVIDIA driver is `410.48` or higher
* Ensure CUDA 10.0+ is installed
* Verify NVIDIA driver is `450.80.02` or higher
* Ensure CUDA 11.0+ is installed

### Usage

Expand All @@ -309,9 +309,9 @@ flag. Below is a list of the available arguments and their purpose:

| Build Argument | Default Value | Other Value(s) | Purpose |
| --- | --- | --- | --- |
| `CUDA_VERSION` | 10.0 | 10.1, 10.2 | set CUDA version |
| `LINUX_VERSION` | ubuntu16.04 | ubuntu18.04 | set Ubuntu version |
| `CC` & `CXX` | 5 | 7 | set gcc/g++ version; **NOTE:** gcc7 requires Ubuntu 18.04 |
| `CUDA_VERSION` | 11.0 | 11.1, 11.2.2 | set CUDA version |
| `LINUX_VERSION` | ubuntu18.04 | ubuntu20.04 | set Ubuntu version |
| `CC` & `CXX` | 9 | 10 | set gcc/g++ version |
| `CUDF_REPO` | This repo | Forks of cuDF | set git URL to use for `git clone` |
| `CUDF_BRANCH` | main | Any branch name | set git branch to checkout of `CUDF_REPO` |
| `NUMBA_VERSION` | newest | >=0.40.0 | set numba version |
Expand Down
30 changes: 12 additions & 18 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,18 +1,20 @@
# Copyright (c) 2021, NVIDIA CORPORATION.

# An integration test & dev container which builds and installs cuDF from main
ARG CUDA_VERSION=10.1
ARG CUDA_VERSION=11.0
ARG CUDA_SHORT_VERSION=${CUDA_VERSION}
ARG LINUX_VERSION=ubuntu16.04
ARG LINUX_VERSION=ubuntu18.04
FROM nvidia/cuda:${CUDA_VERSION}-devel-${LINUX_VERSION}
ENV LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/usr/local/cuda/lib64:/usr/local/lib
# Needed for cudf.concat(), avoids "OSError: library nvvm not found"
ENV NUMBAPRO_NVVM=/usr/local/cuda/nvvm/lib64/libnvvm.so
ENV NUMBAPRO_LIBDEVICE=/usr/local/cuda/nvvm/libdevice/
ENV DEBIAN_FRONTEND=noninteractive

ARG CC=5
ARG CXX=5
ARG CC=9
ARG CXX=9
RUN apt update -y --fix-missing && \
apt upgrade -y && \
apt install -y --no-install-recommends software-properties-common && \
add-apt-repository ppa:ubuntu-toolchain-r/test && \
apt update -y --fix-missing && \
apt install -y --no-install-recommends \
git \
gcc-${CC} \
Expand Down Expand Up @@ -66,18 +68,10 @@ RUN if [ -f /cudf/docker/package_versions.sh ]; \
conda env create --name cudf --file /cudf/conda/environments/cudf_dev_cuda${CUDA_SHORT_VERSION}.yml ; \
fi

# libcudf build/install
ENV CC=/usr/bin/gcc-${CC}
ENV CXX=/usr/bin/g++-${CXX}
RUN source activate cudf && \
mkdir -p /cudf/cpp/build && \
cd /cudf/cpp/build && \
cmake .. -DCMAKE_INSTALL_PREFIX=${CONDA_PREFIX} && \
make -j"$(nproc)" install

# cuDF build/install
# libcudf & cudf build/install
RUN source activate cudf && \
cd /cudf/python/cudf && \
python setup.py build_ext --inplace && \
python setup.py install && \
python setup.py install
cd /cudf/ && \
./build.sh libcudf cudf
4 changes: 2 additions & 2 deletions ci/cpu/prebuild.sh
Original file line number Diff line number Diff line change
Expand Up @@ -14,14 +14,14 @@ else
fi

# upload cudf_kafka for all versions of Python
if [[ "$CUDA" == "10.1" ]]; then
if [[ "$CUDA" == "11.0" ]]; then
export UPLOAD_CUDF_KAFKA=1
else
export UPLOAD_CUDF_KAFKA=0
fi

#We only want to upload libcudf_kafka once per python/CUDA combo
if [[ "$PYTHON" == "3.7" ]] && [[ "$CUDA" == "10.1" ]]; then
if [[ "$PYTHON" == "3.7" ]] && [[ "$CUDA" == "11.0" ]]; then
export UPLOAD_LIBCUDF_KAFKA=1
else
export UPLOAD_LIBCUDF_KAFKA=0
Expand Down
67 changes: 0 additions & 67 deletions conda/environments/cudf_dev_cuda10.1.yml

This file was deleted.

67 changes: 0 additions & 67 deletions conda/environments/cudf_dev_cuda10.2.yml

This file was deleted.

2 changes: 1 addition & 1 deletion conda/environments/cudf_dev_cuda11.0.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ dependencies:
- python>=3.7,<3.9
- numba>=0.49,!=0.51.0
- numpy
- pandas>=1.0,<1.3.0dev0
- pandas>=1.0,<=1.2.4
- pyarrow=1.0.1
- fastavro>=0.22.9
- notebook>=0.5.0
Expand Down
2 changes: 1 addition & 1 deletion conda/environments/cudf_dev_cuda11.1.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ dependencies:
- python>=3.7,<3.9
- numba>=0.49,!=0.51.0
- numpy
- pandas>=1.0,<1.3.0dev0
- pandas>=1.0,<=1.2.4
- pyarrow=1.0.1
- fastavro>=0.22.9
- notebook>=0.5.0
Expand Down
2 changes: 1 addition & 1 deletion conda/environments/cudf_dev_cuda11.2.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ dependencies:
- python>=3.7,<3.9
- numba>=0.49,!=0.51.0
- numpy
- pandas>=1.0,<1.3.0dev0
- pandas>=1.0,<=1.2.4
- pyarrow=1.0.1
- fastavro>=0.22.9
- notebook>=0.5.0
Expand Down
2 changes: 1 addition & 1 deletion conda/recipes/cudf/meta.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ requirements:
- protobuf
- python
- typing_extensions
- pandas >=1.0,<1.3.0dev0
- pandas >=1.0,<=1.2.4
- cupy >7.1.0,<9.0.0a0
- numba >=0.49.0
- numpy
Expand Down
5 changes: 3 additions & 2 deletions cpp/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -210,8 +210,8 @@ add_library(cudf
src/groupby/sort/sort_helper.cu
src/hash/hashing.cu
src/interop/dlpack.cpp
src/interop/from_arrow.cpp
src/interop/to_arrow.cpp
src/interop/from_arrow.cu
src/interop/to_arrow.cu
src/io/avro/avro.cpp
src/io/avro/avro_gpu.cu
src/io/avro/reader_impl.cu
Expand Down Expand Up @@ -247,6 +247,7 @@ add_library(cudf
src/io/parquet/reader_impl.cu
src/io/parquet/writer_impl.cu
src/io/statistics/column_stats.cu
src/io/utilities/column_buffer.cpp
src/io/utilities/data_sink.cpp
src/io/utilities/datasource.cpp
src/io/utilities/file_io_utilities.cpp
Expand Down
2 changes: 1 addition & 1 deletion cpp/benchmarks/string/json_benchmark.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -113,7 +113,7 @@ static void BM_case(benchmark::State& state, QueryArg&&... query_arg)
std::string json_path(query_arg...);

for (auto _ : state) {
cuda_event_timer raii(state, true, 0);
cuda_event_timer raii(state, true);
auto result = cudf::strings::get_json_object(scv, json_path);
cudaStreamSynchronize(0);
}
Expand Down
2 changes: 1 addition & 1 deletion cpp/benchmarks/text/ngrams_benchmark.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ static void BM_ngrams(benchmark::State& state, ngrams_type nt)
cudf::strings_column_view input(table->view().column(0));

for (auto _ : state) {
cuda_event_timer raii(state, true, 0);
cuda_event_timer raii(state, true);
switch (nt) {
case ngrams_type::tokens: nvtext::generate_ngrams(input); break;
case ngrams_type::characters: nvtext::generate_character_ngrams(input); break;
Expand Down
2 changes: 1 addition & 1 deletion cpp/benchmarks/text/replace_benchmark.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ static void BM_replace(benchmark::State& state)
cudf::test::strings_column_wrapper replacements({"1", "2", "7", "0"});

for (auto _ : state) {
cuda_event_timer raii(state, true, 0);
cuda_event_timer raii(state, true);
nvtext::replace_tokens(
view, cudf::strings_column_view(targets), cudf::strings_column_view(replacements));
}
Expand Down
2 changes: 1 addition & 1 deletion cpp/cmake/thirdparty/CUDF_GetCPM.cmake
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
set(CPM_DOWNLOAD_VERSION 4fad2eac0a3741df3d9c44b791f9163b74aa7b07) # 0.32.0
set(CPM_DOWNLOAD_VERSION 7644c3a40fc7889f8dee53ce21e85dc390b883dc) # v0.32.1

if(CPM_SOURCE_CACHE)
# Expand relative path. This is important if the provided path contains a tilde (~)
Expand Down
6 changes: 3 additions & 3 deletions cpp/docs/TESTING.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# Unit Testing in libcudf

Unit tests in libcudf are written using
[Google Test](https://github.com/google/googletest/blob/master/googletest/docs/primer.md).
[Google Test](https://github.com/google/googletest/blob/master/docs/primer.md).

**Important:** Instead of including `gtest/gtest.h` directly, use
`#include <cudf_test/cudf_gtest.hpp>`.
Expand Down Expand Up @@ -59,7 +59,7 @@ files, and are therefore preferred in test code over `thrust::device_vector`.

## Base Fixture

All libcudf unit tests should make use of a GTest ["Test Fixture"](https://github.com/google/googletest/blob/master/googletest/docs/primer.md#test-fixtures-using-the-same-data-configuration-for-multiple-tests-same-data-multiple-tests).
All libcudf unit tests should make use of a GTest ["Test Fixture"](https://github.com/google/googletest/blob/master/docs/primer.md#test-fixtures-using-the-same-data-configuration-for-multiple-tests-same-data-multiple-tests).
Even if the fixture is empty, it should inherit from the base fixture `cudf::test::BaseFixture`
found in `include/cudf_test/base_fixture.hpp`. This ensures that RMM is properly initialized and
finalized. `cudf::test::BaseFixture` already inherits from `::testing::Test` and therefore it is
Expand All @@ -75,7 +75,7 @@ class MyTestFiture : public cudf::test::BaseFixture {...};
In general, libcudf features must work across all of the supported types (there are exceptions e.g.
not all binary operations are supported for all types). In order to automate the process of running
the same tests across multiple types, we use GTest's
[Typed Tests](https://github.com/google/googletest/blob/master/googletest/docs/advanced.md#typed-tests).
[Typed Tests](https://github.com/google/googletest/blob/master/docs/advanced.md#typed-tests).
Typed tests allow you to write a test once and run it across a list of types.
For example:
Expand Down
Loading

0 comments on commit e0f1b5c

Please sign in to comment.