Unverified Commit e5ca8846 authored by Kai Chen's avatar Kai Chen Committed by GitHub
Browse files

Fix the compiling bug when using `pip install mmcv` (#88)

* rename flowWarp to FlowWarp

* fix the compiling bug when using pip install

* update version to v0.2.10
parent 0ad15a50
include mmcv/video/optflow_warp/*.hpp
\ No newline at end of file
__version__ = '0.2.9'
__version__ = '0.2.10'
#include <flow_warp.hpp>
#include "flow_warp.hpp"
void flowWarp(double* img, double* flow, double* out, const int height,
void FlowWarp(double* img, double* flow, double* out, const int height,
const int width, const int channels, const int filling_value = 0,
const int interpolateMode = 0) {
for (int h = 0; h < height; h++) {
......
......@@ -4,7 +4,7 @@
using namespace std;
void flowWarp(double* img, double* flow1, double* out, const int height,
void FlowWarp(double* img, double* flow1, double* out, const int height,
const int width, const int channels, const int filling_value,
const int interpolateMode);
......
......@@ -6,7 +6,7 @@ cimport numpy as np
np.import_array()
cdef extern from "flow_warp.hpp":
void flowWarp(double* img, double* flow1, double* out, const int height, const int width, const int channels, const int filling_value, const int interpolateMode)
void FlowWarp(double* img, double* flow1, double* out, const int height, const int width, const int channels, const int filling_value, const int interpolateMode)
def flow_warp_c(np.ndarray[double, ndim=3, mode="c"] img_array not None,
np.ndarray[double, ndim=3, mode="c"] flow_array not None,
......@@ -15,7 +15,7 @@ def flow_warp_c(np.ndarray[double, ndim=3, mode="c"] img_array not None,
out_array = np.zeros_like(img_array)
flowWarp(<double*> np.PyArray_DATA(img_array),
FlowWarp(<double*> np.PyArray_DATA(img_array),
<double*> np.PyArray_DATA(flow_array),
<double*> np.PyArray_DATA(out_array),
out_array.shape[0],
......
......@@ -36,7 +36,7 @@ EXT_MODULES = [
'./mmcv/video/optflow_warp/flow_warp.cpp',
'./mmcv/video/optflow_warp/flow_warp_module.pyx'
],
include_dirs=[numpy.get_include(), './mmcv/video/optflow_warp/'],
include_dirs=[numpy.get_include()],
language="c++",
),
]
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment