Git Product home page Git Product logo

netdef_models's People

Contributors

eddy-ilg avatar nikolausmayer avatar tonmoy-saikia avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

netdef_models's Issues

Controller eval code wrong in readme (part 1)

When I tried to run your examples code I get this:

import netdef_slim as nd
nd.load_module('FlowNet3/CSS/controller.py')
Using /home/brisa/frbarbos/lmbspecialops/build/lib/lmbspecialops.so
<module 'None' from 'FlowNet3/CSS/controller.py'>
c = Controller()
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
NameError: name 'Controller' is not defined

I found to possible solutions:

  1. save the output of load_module is a variable:
import netdef_slim as nd
M = nd.load_module('FlowNet3/CSS/controller.py')
Using /home/brisa/frbarbos/lmbspecialops/build/lib/lmbspecialops.so
c = M.Controller()
evolution <00__flyingThings3D.train__S_fine_half>: 00__flyingThings3D.train__S_fine_half        COMPLETE
  1. Using directly Controller in the load_module output:
import netdef_slim as nd
c = nd.load_module('FlowNet3/CSS/controller.py').Controller()
Using /home/brisa/frbarbos/lmbspecialops/build/lib/lmbspecialops.so
evolution <00__flyingThings3D.train__S_fine_half>: 00__flyingThings3D.train__S_fine_half        COMPLETE

Controller eval code wrong in readme (part 2)

out = c.net_actions.eval(img0, img1) returns:

Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
TypeError: eval() missing 1 required positional argument: 'image_1'

(using tried with img0 and img1 as path to the image and as numpy array)

Error on "python3 controller.py " in occ-fill

I was trying to running the script below in SceneFlow/occ-fill folder:
python3 controller.py eval --imgs_t0 test_images/t0_imgL.png test_images/t0_imgR.png --imgs_t1 test_images/t1_imgL.png test_images/t1_imgR.png --dn_path ../../DispNet3/CSS/ --fn_path ../../FlowNet3/CSS/
But I got following error message:
FileNotFoundError: [Errno 2] No such file or directory: '../../DispNet3/CSS/training/00__flyingThings3D.train__S_custom/checkpoints'
I sure there is a folder in my computer named ../../DispNet3/CSS/training/00__flyingThings3D.train__S_short/checkpoints' after bash download_snapshots.sh
Any solution? thanks.

Near-duplicate commands in download_snapshots.sh

Trying to load training snapshots on Win10 using Debian Linux subsystem.
A couple of the shell scripts contain neera-duplicat line pairs like
download css 00__flyingThings3D.train__S_fine_half 250000
download CSS 00__flyingThings3D.train__S_fine_half 250000
If this is intended to create two different directories, it fails on Windows -- the second command overwrites the output of the first. Moreover if the two downloads have identical contents, as would appear to be the case, it would be much quicker to copy the first one to another directory rather than download again.
Or is this an editing error?

Error on "python3 controller.py eval image0_path image1_path out_dir"

"lmbspecialops" is built correctly and the small example (provided in this page) ran without any error.

By running the script below (providing the path for image0_path, image1_path and out_dir):
python3 controller.py eval image0_path image1_path out_dir

The following error happens:

...
from lmbspecialops import correlation as correlation
ImportError: cannot import name 'correlation'

FlowNetH training

I just wanna to know if step training used in FlowNetH( 1st train hypNet, then mergeNet, or train the whole net ) , and the batch size. It can't be find in paper! Many thanks

"python3 controller.py eval image0_path image1_path out_dir" wrong output

I'm running this:

python controller.py eval ../../../test/001.jpg ../../../test/002.jpg ../../../test/

And I get this:

ls ../../../test
001.jpg  002.jpg  'flow[0].fwd.flo'        'occ[0].fwd.float3'
001.png  002.png  'mb[0].fwd.float3'       'occ_soft[0].fwd.float3'
001.tif  002.tif  'mb_soft[0].fwd.float3'

I found really rare that files have apostrophes.

I tried your read code:

from netdef_slim.utils.io import read 
occ_file = '\\'flow[0].fwd.flo\\''
occ_data = read(occ_file) # returns a numpy array

import matplotlib.pyplot as plt
plt.imshow(occ_data[:,:,0])

And gets:

Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
TypeError: 'NoneType' object is not subscriptable

Wrong command in README

The README says to execute:
python3 controller.py image0_path image1_path out_dir

This results in an error message. The README is missing the selection of the actual command to be executed {eval,perf-test,list-evos,list-states}.

Doesn't work for grayscale images

netdef_slim package doesn't work for grayscale images, only for RGB images. Which is a problem with datasets like UCSD that is composed of grayscale TIFF images.

Can I run this code on non-GPU machine

When I compile lmbspecialops with BUILD_WITH_CUDA=OFF, I run the controller.py of css in dispnet3 and I get the following error:
InvalidArgumentError (see above for traceback): No OpKernel was registered to support Op 'Correlation1D' with these attrs. Registered devices: [CPU], Registered kernels:
  [[Node: net1/upper/Correlation1D = Correlation1D[T=DT_FLOAT, corr_type="mult", do_abs=false, kernel_size=1, max_displacement=40, pad_size=40, single_dir=0, stride1=1, stride2=1] (net1/features/conv3/LeakyRelu, net1/features/conv3_2/LeakyRelu)]]

When I compile lmbspecialops with BUILD_WITH_CUDA=on, there is no problem
So I want to know if this code can run on a machine without a GPU.
Thank you

InvalidArgumentError: No OpKernel was registered to support Op 'Correlation1D' with these attrs. Registered devices: [CPU]

ubuntu16.04
tensorflow=1.4(NO GPU)
python:3.6.4
lmbspecialops:eccv18
when I run the demo(dispnet3):
python3 controller.py eval image0_path image1_path out_dir
I get the follow errors:
evolution <00__flyingThings3D.train__S_short>: 00__flyingThings3D.train__S_short COMPLETE
data:
OrderedDict([('width', 960), ('height', 540), ('img', <netdef_slim.tensorflow.core.struct._Struct object at 0x7f4ec26f7dd8>)]
Evo manager: complete
Evolution: /home/itx/PycharmProjects/netdef_models-master/DispNet3/css/training/00__flyingThings3D.train__S_short
pred:
OrderedDict([('levels', <netdef_slim.tensorflow.core.struct._Struct object at 0x7f4ebbfcbf28>), ('final', <netdef_slim.tensorflow.core.struct._Struct object at 0x7f4ebbb5e2e8>)]
output:
OrderedDict([('disp', <netdef_slim.tensorflow.core.struct._Struct object at 0x7f4ede604fd0>), ('occ', <netdef_slim.tensorflow.core.struct._Struct object at 0x7f4ef0afa748>), ('db', <netdef_slim.tensorflow.core.struct._Struct object at 0x7f4ebc26ff28>)]
Traceback (most recent call last):
File "/home/itx/tools/anaconda3/lib/python3.6/site-packages/tensorflow/python/client/session.py", line 1323, in _do_call
return fn(*args)
File "/home/itx/tools/anaconda3/lib/python3.6/site-packages/tensorflow/python/client/session.py", line 1293, in _run_fn
self._extend_graph()
File "/home/itx/tools/anaconda3/lib/python3.6/site-packages/tensorflow/python/client/session.py", line 1354, in _extend_graph
self._session, graph_def.SerializeToString(), status)
File "/home/itx/tools/anaconda3/lib/python3.6/site-packages/tensorflow/python/framework/errors_impl.py", line 473, in exit
c_api.TF_GetCode(self.status.status))
tensorflow.python.framework.errors_impl.InvalidArgumentError: No OpKernel was registered to support Op 'Correlation1D' with these attrs. Registered devices: [CPU], Registered kernels:

 [[Node: net1/upper/Correlation1D = Correlation1D[T=DT_FLOAT, corr_type="mult", do_abs=false, kernel_size=1, max_displacement=40, pad_size=40, single_dir=0, stride1=1, stride2=1](net1/features/conv3/LeakyRelu, net1/features/conv3_2/LeakyRelu)]]

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "/home/itx/PycharmProjects/netdef_models-master/DispNet3/css/controller.py", line 19, in
controller.run()
File "/home/itx/PycharmProjects/netdef_models-master/DispNet3/css/netdef_slim/tensorflow/controller/base_controller.py", line 36, in run
self._command_hookscommand
File "/home/itx/PycharmProjects/netdef_models-master/DispNet3/css/netdef_slim/tensorflow/controller/base_controller.py", line 53, in eval
state=self._args.state)
File "/home/itx/PycharmProjects/netdef_models-master/DispNet3/css/netdef_slim/tensorflow/controller/base_controller.py", line 91, in eval
output = self.net_actions(net_dir=self.base_path).eval(**kwargs)
File "/home/itx/PycharmProjects/netdef_models-master/DispNet3/css/netdef_slim/tensorflow/controller/net_actions.py", line 54, in eval
session.run(tf.global_variables_initializer())
File "/home/itx/tools/anaconda3/lib/python3.6/site-packages/tensorflow/python/client/session.py", line 889, in run
run_metadata_ptr)
File "/home/itx/tools/anaconda3/lib/python3.6/site-packages/tensorflow/python/client/session.py", line 1120, in _run
feed_dict_tensor, options, run_metadata)
File "/home/itx/tools/anaconda3/lib/python3.6/site-packages/tensorflow/python/client/session.py", line 1317, in _do_run
options, run_metadata)
File "/home/itx/tools/anaconda3/lib/python3.6/site-packages/tensorflow/python/client/session.py", line 1336, in _do_call
raise type(e)(node_def, op, message)
tensorflow.python.framework.errors_impl.InvalidArgumentError: No OpKernel was registered to support Op 'Correlation1D' with these attrs. Registered devices: [CPU], Registered kernels:

 [[Node: net1/upper/Correlation1D = Correlation1D[T=DT_FLOAT, corr_type="mult", do_abs=false, kernel_size=1, max_displacement=40, pad_size=40, single_dir=0, stride1=1, stride2=1](net1/features/conv3/LeakyRelu, net1/features/conv3_2/LeakyRelu)]]

Caused by op 'net1/upper/Correlation1D', defined at:
File "/home/itx/PycharmProjects/netdef_models-master/DispNet3/css/controller.py", line 19, in
controller.run()
File "/home/itx/PycharmProjects/netdef_models-master/DispNet3/css/netdef_slim/tensorflow/controller/base_controller.py", line 36, in run
self._command_hookscommand
File "/home/itx/PycharmProjects/netdef_models-master/DispNet3/css/netdef_slim/tensorflow/controller/base_controller.py", line 53, in eval
state=self._args.state)
File "/home/itx/PycharmProjects/netdef_models-master/DispNet3/css/netdef_slim/tensorflow/controller/base_controller.py", line 91, in eval
output = self.net_actions(net_dir=self.base_path).eval(**kwargs)
File "/home/itx/PycharmProjects/netdef_models-master/DispNet3/css/netdef_slim/tensorflow/controller/net_actions.py", line 50, in eval
height = height,
File "/home/itx/PycharmProjects/netdef_models-master/DispNet3/css/netdef_slim/networks/dispnet/dispnet_2f_env.py", line 29, in make_eval_graph
scale = scale
File "/home/itx/PycharmProjects/netdef_models-master/DispNet3/css/netdef_slim/deploy/std_deployment.py", line 156, in make_graph
pred = net_graph_constructor(input)
File "/home/itx/PycharmProjects/netdef_models-master/DispNet3/css/netdef_slim/networks/dispnet/dispnet_2f_env.py", line 27, in
net_graph_constructor=lambda data: self.make_net_graph(data, include_losses=False),
File "/home/itx/PycharmProjects/netdef_models-master/DispNet3/css/netdef_slim/networks/dispnet/dispnet_2f_env.py", line 15, in make_net_graph
return self._net.make_graph(data, **kwargs)
File "/home/itx/PycharmProjects/netdef_models-master/DispNet3/css/net.py", line 40, in make_graph
out1 = arch1.make_graph(data.img.L, data.img.R, use_1D_corr=True, single_direction=0)
File "/home/itx/PycharmProjects/netdef_models-master/DispNet3/css/netdef_slim/architectures/architecture_c.py", line 260, in make_graph
out = self._upper.make_graph(feat, edge_features, use_1D_corr, single_direction)
File "/home/itx/PycharmProjects/netdef_models-master/DispNet3/css/netdef_slim/architectures/architecture_c.py", line 143, in make_graph
single_direction=single_direction
File "/home/itx/PycharmProjects/netdef_models-master/DispNet3/css/netdef_slim/tensorflow/core/ops/flow_disp.py", line 70, in _correlation_1d
pad_size=pad)
File "", line 616, in correlation1d
File "/home/itx/tools/anaconda3/lib/python3.6/site-packages/tensorflow/python/framework/op_def_library.py", line 328, in apply_op
op_type_name, name, **keywords)
File "/home/itx/tools/anaconda3/lib/python3.6/site-packages/tensorflow/python/framework/op_def_library.py", line 787, in _apply_op_helper
op_def=op_def)
File "/home/itx/tools/anaconda3/lib/python3.6/site-packages/tensorflow/python/framework/ops.py", line 2956, in create_op
op_def=op_def)
File "/home/itx/tools/anaconda3/lib/python3.6/site-packages/tensorflow/python/framework/ops.py", line 1470, in init
self._traceback = self._graph._extract_stack() # pylint: disable=protected-access

InvalidArgumentError (see above for traceback): No OpKernel was registered to support Op 'Correlation1D' with these attrs. Registered devices: [CPU], Registered kernels:

 [[Node: net1/upper/Correlation1D = Correlation1D[T=DT_FLOAT, corr_type="mult", do_abs=false, kernel_size=1, max_displacement=40, pad_size=40, single_dir=0, stride1=1, stride2=1](net1/features/conv3/LeakyRelu, net1/features/conv3_2/LeakyRelu)]]

Process finished with exit code 1

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.