mirror of
https://github.com/pytorch/pytorch.git
synced 2025-10-20 21:14:14 +08:00
Fix the CMake issues caused by internal changes
This commit is contained in:
@ -21,6 +21,7 @@ add_subdirectory(mpi)
|
|||||||
add_subdirectory(observers)
|
add_subdirectory(observers)
|
||||||
add_subdirectory(onnx)
|
add_subdirectory(onnx)
|
||||||
add_subdirectory(operators)
|
add_subdirectory(operators)
|
||||||
|
add_subdirectory(operators/rnn)
|
||||||
add_subdirectory(perfkernels)
|
add_subdirectory(perfkernels)
|
||||||
add_subdirectory(python)
|
add_subdirectory(python)
|
||||||
add_subdirectory(queue)
|
add_subdirectory(queue)
|
||||||
|
40
caffe2/operators/rnn/CMakeLists.txt
Normal file
40
caffe2/operators/rnn/CMakeLists.txt
Normal file
@ -0,0 +1,40 @@
|
|||||||
|
# ---[ GPU files
|
||||||
|
# ------[ cuDNN
|
||||||
|
file(GLOB tmp *_cudnn.cc)
|
||||||
|
set(Caffe2_GPU_SRCS ${Caffe2_GPU_SRCS} ${tmp})
|
||||||
|
# ------[ general GPU
|
||||||
|
file(GLOB tmp *_gpu.cc)
|
||||||
|
set(Caffe2_GPU_SRCS ${Caffe2_GPU_SRCS} ${tmp})
|
||||||
|
# ------[ CUDA sources
|
||||||
|
file(GLOB tmp *.cu)
|
||||||
|
set(Caffe2_GPU_SRCS ${Caffe2_GPU_SRCS} ${tmp})
|
||||||
|
# exclude test files
|
||||||
|
file(GLOB tmp *_test.cc)
|
||||||
|
exclude(Caffe2_GPU_SRCS "${Caffe2_GPU_SRCS}" ${tmp})
|
||||||
|
|
||||||
|
# ---[ CPU files.
|
||||||
|
file(GLOB tmp *.cc)
|
||||||
|
set(Caffe2_CPU_SRCS ${Caffe2_CPU_SRCS} ${tmp})
|
||||||
|
# exclude test files and gpu files
|
||||||
|
file(GLOB tmp *_test.cc)
|
||||||
|
exclude(Caffe2_CPU_SRCS "${Caffe2_CPU_SRCS}" ${tmp})
|
||||||
|
exclude(Caffe2_CPU_SRCS "${Caffe2_CPU_SRCS}" ${Caffe2_GPU_SRCS})
|
||||||
|
|
||||||
|
# ---[ GPU test files
|
||||||
|
# ------[ cuDNN
|
||||||
|
file(GLOB tmp *_cudnn_test.cc)
|
||||||
|
set(Caffe2_GPU_TEST_SRCS ${Caffe2_GPU_TEST_SRCS} ${tmp})
|
||||||
|
# ------[ general GPU
|
||||||
|
file(GLOB tmp *_gpu_test.cc)
|
||||||
|
set(Caffe2_GPU_TEST_SRCS ${Caffe2_GPU_TEST_SRCS} ${tmp})
|
||||||
|
|
||||||
|
# ---[ CPU test files
|
||||||
|
file(GLOB tmp *_test.cc)
|
||||||
|
set(Caffe2_CPU_TEST_SRCS ${Caffe2_CPU_TEST_SRCS} ${tmp})
|
||||||
|
exclude(Caffe2_CPU_TEST_SRCS "${Caffe2_CPU_TEST_SRCS}" ${Caffe2_GPU_TEST_SRCS})
|
||||||
|
|
||||||
|
# ---[ Send the lists to the parent scope.
|
||||||
|
set(Caffe2_CPU_SRCS ${Caffe2_CPU_SRCS} PARENT_SCOPE)
|
||||||
|
set(Caffe2_GPU_SRCS ${Caffe2_GPU_SRCS} PARENT_SCOPE)
|
||||||
|
set(Caffe2_CPU_TEST_SRCS ${Caffe2_CPU_TEST_SRCS} PARENT_SCOPE)
|
||||||
|
set(Caffe2_GPU_TEST_SRCS ${Caffe2_GPU_TEST_SRCS} PARENT_SCOPE)
|
@ -5,7 +5,6 @@
|
|||||||
#include "caffe2/core/logging.h"
|
#include "caffe2/core/logging.h"
|
||||||
#include "caffe2/core/operator.h"
|
#include "caffe2/core/operator.h"
|
||||||
#include "caffe2/core/tensor.h"
|
#include "caffe2/core/tensor.h"
|
||||||
#include "caffe2/operators/recurrent_network_op.h"
|
|
||||||
#include "caffe2/operators/rnn/recurrent_network_op.h"
|
#include "caffe2/operators/rnn/recurrent_network_op.h"
|
||||||
#include "google/protobuf/text_format.h"
|
#include "google/protobuf/text_format.h"
|
||||||
|
|
||||||
|
20
caffe2/python/rnn/__init__.py
Normal file
20
caffe2/python/rnn/__init__.py
Normal file
@ -0,0 +1,20 @@
|
|||||||
|
# Copyright (c) 2016-present, Facebook, Inc.
|
||||||
|
#
|
||||||
|
# Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
# you may not use this file except in compliance with the License.
|
||||||
|
# You may obtain a copy of the License at
|
||||||
|
#
|
||||||
|
# http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
#
|
||||||
|
# Unless required by applicable law or agreed to in writing, software
|
||||||
|
# distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
|
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
|
# See the License for the specific language governing permissions and
|
||||||
|
# limitations under the License.
|
||||||
|
##############################################################################
|
||||||
|
|
||||||
|
from __future__ import absolute_import
|
||||||
|
from __future__ import division
|
||||||
|
from __future__ import print_function
|
||||||
|
from __future__ import unicode_literals
|
||||||
|
|
Reference in New Issue
Block a user