Skip to content
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
36 changes: 36 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
FROM nvcr.io/nvidia/pytorch:19.10-py3
MAINTAINER Stephen Neuendorffer <stephenn@xilinx.com>

#
# get the basics
#
USER root
ENV DEBIAN_FRONTEND=noninteractive

RUN apt-get update
RUN apt-get install software-properties-common --assume-yes
RUN apt-get install wget curl unzip libxml2-dev --assume-yes
RUN apt-get install autoconf libtool g++ g++-multilib --assume-yes
RUN apt-get install build-essential python3 cmake git gitk --assume-yes
RUN apt-get install clang-8 lld-8 ninja-build --assume-yes
RUN apt-get install libncurses5-dev --assume-yes

RUN /opt/conda/bin/conda install matplotlib pybind11
#torchvision

ENV LD_LIBRARY_PATH "${LD_LIBRARY_PATH}:/opt/conda/lib"

# Rebuild pytorch

WORKDIR /opt/pytorch/pytorch

# this is the recommended rebuild command from NVIDIA
# with the cleanup of the build area omitted.
RUN TORCH_CUDA_ARCH_LIST="5.2 6.0 6.1 7.0 7.5+PTX" \
CMAKE_PREFIX_PATH="$(dirname $(which conda))/../" \
NCCL_INCLUDE_DIR="/usr/include/" \
NCCL_LIB_DIR="/usr/lib/" \
python setup.py install

WORKDIR /workspace

2 changes: 1 addition & 1 deletion frontends/pytorch/csrc/type_dispatch/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ add_library(npcomp_torch_type_dispatch_bindings
)

get_property(mlir_libs GLOBAL PROPERTY MLIR_ALL_LIBS)
target_link_libraries(_torch_mlir
target_link_libraries(npcomp_torch_type_dispatch_bindings
NPCOMPATenDialect
${TORCH_LIBRARIES}
${mlir_libs}
Expand Down
2 changes: 1 addition & 1 deletion frontends/pytorch/csrc/type_dispatch/python_bindings.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -127,7 +127,7 @@ void InitModuleBindings(py::module &m) {
module->print(ss);
return ss.str();
});

}
} // namespace

void InitTypeDispatchBindings(py::module &m) { InitModuleBindings(m); }
Expand Down