yzygitzh / humanoid Goto Github PK
View Code? Open in Web Editor NEWExplore Android apps like human.
Explore Android apps like human.
Hello,
I am using Python 3.8.5, tensorflow 2.7.0. I followed all installation steps and when trying to run I get this error:
"ModuleNotFoundError: No module named 'tensorflow.contrib'"
How to solve this problem?
我发现一个错误,和数据集相关的:
assert(len(gestures) == len(view_tree_tags)) # 操作数目=页面层次结构数目
请问一下,我下载的数据集中view_tree_tags会缺失,即gesture有的ui,在view_tree_tags里面没有,这个怎么解决啊?你下载的链接是这个吗:http://interactionmining.org/
感激不尽!
2023-06-04 10:03:01.085984: W tensorflow/compiler/tf2tensorrt/utils/py_utils.cc:38] TF-TRT Warning: Could not find TensorRT
Traceback (most recent call last):
File "/workspaces/Humanoid/agent.py", line 15, in
tf_config = tf.ConfigProto()
AttributeError: module 'tensorflow' has no attribute 'ConfigProto'
I got indexerror when training, traceback:
image ['0.0' '0.0' '0.0'
'/mnt/e/chrome_download/filtered_traces/com.snupps.snuppsdroid/trace_0/view_hierarchies/1.json']
image.shape (4,)
Exception in thread Thread-2:
Traceback (most recent call last):
File "/home/syx/miniconda3/envs/py37/lib/python3.7/threading.py", line 926, in _bootstrap_inner
self.run()
File "/home/syx/miniconda3/envs/py37/lib/python3.7/threading.py", line 870, in run
self._target(*self._args, **self._kwargs)
File "/home/syx/infortest/Humanoid/train/loader.py", line 166, in next_batch_producer
self.load_pickles(paths_to_load)
File "/home/syx/infortest/Humanoid/train/loader.py", line 128, in load_pickles
image[self.frame_num - 1, :, :, -self.predicting_dim:] = 0.0
IndexError: too many indices for array: array is 1-dimensional, but 4 were indexed
training_data and validation_data is as bellow:
Thanks.
problem encountered:
steps:
test env:
The training loop and most of everything seems deprecated. Would it be possible to update the code so that others can use this project as a benchmark for research? What is the output tensor shape of the model?
Hi, I'm trying to prepare the data like in scripts within "rico" folder, I could run the code, but the pickle files show just an empty dictionary {'trace_0': []}. Do you have a solution? I run the code with python 2.7.18
Hello,
I am using Python 3.6.7, tensorflow 1.12.0 on Windows 10.
Humanoid was installed successfully on my machine.
But, I found problem when try to running the command "python agent.py -c config.json"
I got the following response:
D:\Lab\AIG-Ref\Humanoid-master>python agent.py -c config.json
C:\Users\Rajif\AppData\Local\Programs\Python\Python36\lib\site-packages\tensorflow\python\framework\dtypes.py:523: FutureWarning: Passing (type, 1) or '1type' as a synonym of type is deprecated; in a future version of numpy, it will be understood as (type, (1,)) / '(1,)type'.
_np_qint8 = np.dtype([("qint8", np.int8, 1)])
C:\Users\Rajif\AppData\Local\Programs\Python\Python36\lib\site-packages\tensorflow\python\framework\dtypes.py:524: FutureWarning: Passing (type, 1) or '1type' as a synonym of type is deprecated; in a future version of numpy, it will be understood as (type, (1,)) / '(1,)type'.
_np_quint8 = np.dtype([("quint8", np.uint8, 1)])
C:\Users\Rajif\AppData\Local\Programs\Python\Python36\lib\site-packages\tensorflow\python\framework\dtypes.py:525: FutureWarning: Passing (type, 1) or '1type' as a synonym of type is deprecated; in a future version of numpy, it will be understood as (type, (1,)) / '(1,)type'.
_np_qint16 = np.dtype([("qint16", np.int16, 1)])
C:\Users\Rajif\AppData\Local\Programs\Python\Python36\lib\site-packages\tensorflow\python\framework\dtypes.py:526: FutureWarning: Passing (type, 1) or '1type' as a synonym of type is deprecated; in a future version of numpy, it will be understood as (type, (1,)) / '(1,)type'.
_np_quint16 = np.dtype([("quint16", np.uint16, 1)])
C:\Users\Rajif\AppData\Local\Programs\Python\Python36\lib\site-packages\tensorflow\python\framework\dtypes.py:527: FutureWarning: Passing (type, 1) or '1type' as a synonym of type is deprecated; in a future version of numpy, it will be understood as (type, (1,)) / '(1,)type'.
_np_qint32 = np.dtype([("qint32", np.int32, 1)])
C:\Users\Rajif\AppData\Local\Programs\Python\Python36\lib\site-packages\tensorflow\python\framework\dtypes.py:532: FutureWarning: Passing (type, 1) or '1type' as a synonym of type is deprecated; in a future version of numpy, it will be understood as (type, (1,)) / '(1,)type'.
np_resource = np.dtype([("resource", np.ubyte, 1)])
Serving at localhost:50405
Traceback (most recent call last):
File "agent.py", line 392, in <module>
main()
File "agent.py", line 388, in main
run(opts.config_path)
File "agent.py", line 376, in run
agent = HumanoidAgent(config_json)
File "agent.py", line 234, in __init__
self.text_generator = TextGenerator(config_json)
File "agent.py", line 36, in __init__
self.embedding = json.load(f)
File "C:\Users\Rajif\AppData\Local\Programs\Python\Python36\lib\json\__init__.py", line 296, in load
return loads(fp.read(),
File "C:\Users\Rajif\AppData\Local\Programs\Python\Python36\lib\encodings\cp1252.py", line 23, in decode
return codecs.charmap_decode(input,self.errors,decoding_table)[0]
UnicodeDecodeError: 'charmap' codec can't decode byte 0x81 in position 25926717: character maps to <undefined>
Is there any suggestion to fix this problem?
Traceback (most recent call last):
File "/home/syx/miniconda3/envs/py37/lib/python3.7/site-packages/tensorflow/python/client/session.py", line 1334, in _do_call
return fn(*args)
File "/home/syx/miniconda3/envs/py37/lib/python3.7/site-packages/tensorflow/python/client/session.py", line 1319, in _run_fn
options, feed_dict, fetch_list, target_list, run_metadata)
File "/home/syx/miniconda3/envs/py37/lib/python3.7/site-packages/tensorflow/python/client/session.py", line 1407, in _call_tf_sessionrun
run_metadata)
tensorflow.python.framework.errors_impl.AlreadyExistsError: Resource __per_step_2/gradients_11/lstm_2/while/ReadVariableOp_8/Enter_grad/ArithmeticOptimizer/AddOpsRewrite_Add/tmp_var/N10tensorflow19TemporaryVariableOp6TmpVarE
[[{{node gradients_11/lstm_2/while/ReadVariableOp_8/Enter_grad/ArithmeticOptimizer/AddOpsRewrite_Add/tmp_var}}]]
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "train.py", line 112, in
main()
File "train.py", line 108, in main
run(opts.config_path)
File "train.py", line 67, in run
sess.run(final_trainer, feed_dict=feed_dict)
File "/home/syx/miniconda3/envs/py37/lib/python3.7/site-packages/tensorflow/python/client/session.py", line 929, in run
run_metadata_ptr)
File "/home/syx/miniconda3/envs/py37/lib/python3.7/site-packages/tensorflow/python/client/session.py", line 1152, in _run
feed_dict_tensor, options, run_metadata)
File "/home/syx/miniconda3/envs/py37/lib/python3.7/site-packages/tensorflow/python/client/session.py", line 1328, in _do_run
run_metadata)
File "/home/syx/miniconda3/envs/py37/lib/python3.7/site-packages/tensorflow/python/client/session.py", line 1348, in _do_call
raise type(e)(node_def, op, message)
tensorflow.python.framework.errors_impl.AlreadyExistsError: Resource __per_step_2/gradients_11/lstm_2/while/ReadVariableOp_8/Enter_grad/ArithmeticOptimizer/AddOpsRewrite_Add/tmp_var/N10tensorflow19TemporaryVariableOp6TmpVarE
[[{{node gradients_11/lstm_2/while/ReadVariableOp_8/Enter_grad/ArithmeticOptimizer/AddOpsRewrite_Add/tmp_var}}]]
Tested the model on couple applications[1], but I could not pass any input-based activities such as sign up/ log-in and such.
Maybe you should apply some sort of a classifier to identify those classes and act differently.
Why mix python 3.x and 2.x???Why mix python 3.x and 2.x???Why mix python 3.x and 2.x???Why mix python 3.x and 2.x???Why mix python 3.x and 2.x???
Hello everyone,
As mentioned above, I couldn't restore the model properly, there was no checkpoints found.
Is it possible, if anyone is still working on this project, to push any checkpoint.
Thank you
I was wondering if, there is any documentation with how to run the benchmarking of
humanoid against other testing emulators.
Hello, could you please explain to me what is this file? And where I can get this?
I am getting the following error When I run train.py.
What is the right way of doing this ?
root@c7e0a06df25a:~/data/github/Humanoid/train# python train.py -c config.json
2019-12-01 03:27:23.654511: I tensorflow/core/platform/cpu_feature_guard.cc:140] Your CPU supports instructions that this TensorFlow binary was not compiled to use: AVX2 FMA
2019-12-01 03:27:27,901 epoch: 0
image-name ['0.0' '0.0' '0.0'
'/root/data/github/Humanoid/dataset/traces/filtered_traces/com.mobymax.mmdroid/trace_0/view_hierarchies/414.json']
image-data_type <class 'numpy.ndarray'>
self.frame_num 4
self.frame_num_type <class 'int'>
self.predicting_dim 1
self.predicting_dim_type <class 'int'>
Exception in thread Thread-2:
Traceback (most recent call last):
File "/root/anaconda3/lib/python3.6/threading.py", line 916, in _bootstrap_inner
self.run()
File "/root/anaconda3/lib/python3.6/threading.py", line 864, in run
self._target(*self._args, **self._kwargs)
File "/root/data/github/Humanoid/train/loader.py", line 172, in next_batch_producer
self.load_pickles(paths_to_load)
File "/root/data/github/Humanoid/train/loader.py", line 133, in load_pickles
image[self.frame_num - 1, :, :, -self.predicting_dim:] = 0.0
IndexError: too many indices for array
Thanks for the help.
Hi,
This is a very interesting work. Could you please explain the steps of executing scripts to prepare the Rico dataset and train the models? That would help a lot.
Thanks a lot.
Chanh-Duc.
I'm trying to test humanoid, but I'm getting this error.
my env is:
debian 10
tensorflow 1.15 no gpu support
file "agent.py", line 16, in
tf_config.gpu_options.allow_growth = True
AttributeError: 'google.protobuf.pyext._message.FieldProperty' object has no attribute 'allow_growth'
Do anyone know any solution?
Every time I try and run "python3 agent.py -c config.json" i get the following response:
`Serving at localhost:50405
2019-02-05 19:12:58.924352: I tensorflow/core/platform/cpu_feature_guard.cc:140] Your CPU supports instructions that this TensorFlow binary was not compiled to use: AVX2 FMA
2019-02-05 19:12:58.969391: W tensorflow/core/framework/op_kernel.cc:1318] OP_REQUIRES failed at save_restore_v2_ops.cc:184 : Not found: Key lstm/lstm_cell/bias not found in checkpoint
Traceback (most recent call last):
File "/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages/tensorflow/python/client/session.py", line 1322, in _do_call
return fn(*args)
File "/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages/tensorflow/python/client/session.py", line 1307, in _run_fn
options, feed_dict, fetch_list, target_list, run_metadata)
File "/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages/tensorflow/python/client/session.py", line 1409, in _call_tf_sessionrun
run_metadata)
tensorflow.python.framework.errors_impl.NotFoundError: Key lstm/lstm_cell/bias not found in checkpoint
[[Node: save/RestoreV2 = RestoreV2[dtypes=[DT_FLOAT, DT_FLOAT, DT_FLOAT, DT_FLOAT, DT_FLOAT, ..., DT_FLOAT, DT_FLOAT, DT_FLOAT, DT_FLOAT, DT_FLOAT], _device="/job:localhost/replica:0/task:0/device:CPU:0"](_arg_save/Const_0_0, save/RestoreV2/tensor_names, save/RestoreV2/shape_and_slices)]]
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "agent.py", line 393, in
main()
File "agent.py", line 389, in main
run(opts.config_path)
File "agent.py", line 377, in run
agent = HumanoidAgent(config_json)
File "agent.py", line 233, in init
self.saver.restore(self.sess, config_json["model_path"])
File "/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages/tensorflow/python/training/saver.py", line 1802, in restore
{self.saver_def.filename_tensor_name: save_path})
File "/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages/tensorflow/python/client/session.py", line 900, in run
run_metadata_ptr)
File "/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages/tensorflow/python/client/session.py", line 1135, in _run
feed_dict_tensor, options, run_metadata)
File "/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages/tensorflow/python/client/session.py", line 1316, in _do_run
run_metadata)
File "/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages/tensorflow/python/client/session.py", line 1335, in _do_call
raise type(e)(node_def, op, message)
tensorflow.python.framework.errors_impl.NotFoundError: Key lstm/lstm_cell/bias not found in checkpoint
[[Node: save/RestoreV2 = RestoreV2[dtypes=[DT_FLOAT, DT_FLOAT, DT_FLOAT, DT_FLOAT, DT_FLOAT, ..., DT_FLOAT, DT_FLOAT, DT_FLOAT, DT_FLOAT, DT_FLOAT], _device="/job:localhost/replica:0/task:0/device:CPU:0"](_arg_save/Const_0_0, save/RestoreV2/tensor_names, save/RestoreV2/shape_and_slices)]]
Caused by op 'save/RestoreV2', defined at:
File "agent.py", line 393, in
main()
File "agent.py", line 389, in main
run(opts.config_path)
File "agent.py", line 377, in run
agent = HumanoidAgent(config_json)
File "agent.py", line 231, in init
self.saver = tf.train.Saver()
File "/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages/tensorflow/python/training/saver.py", line 1338, in init
self.build()
File "/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages/tensorflow/python/training/saver.py", line 1347, in build
self._build(self._filename, build_save=True, build_restore=True)
File "/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages/tensorflow/python/training/saver.py", line 1384, in _build
build_save=build_save, build_restore=build_restore)
File "/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages/tensorflow/python/training/saver.py", line 835, in _build_internal
restore_sequentially, reshape)
File "/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages/tensorflow/python/training/saver.py", line 472, in _AddRestoreOps
restore_sequentially)
File "/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages/tensorflow/python/training/saver.py", line 886, in bulk_restore
return io_ops.restore_v2(filename_tensor, names, slices, dtypes)
File "/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages/tensorflow/python/ops/gen_io_ops.py", line 1463, in restore_v2
shape_and_slices=shape_and_slices, dtypes=dtypes, name=name)
File "/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages/tensorflow/python/framework/op_def_library.py", line 787, in _apply_op_helper
op_def=op_def)
File "/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages/tensorflow/python/framework/ops.py", line 3392, in create_op
op_def=op_def)
File "/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages/tensorflow/python/framework/ops.py", line 1718, in init
self._traceback = self._graph._extract_stack() # pylint: disable=protected-access
NotFoundError (see above for traceback): Key lstm/lstm_cell/bias not found in checkpoint
[[Node: save/RestoreV2 = RestoreV2[dtypes=[DT_FLOAT, DT_FLOAT, DT_FLOAT, DT_FLOAT, DT_FLOAT, ..., DT_FLOAT, DT_FLOAT, DT_FLOAT, DT_FLOAT, DT_FLOAT], _device="/job:localhost/replica:0/task:0/device:CPU:0"](_arg_save/Const_0_0, save/RestoreV2/tensor_names, save/RestoreV2/shape_and_slices)]]`
I have all the necessary dependencies etc and am running Python 3.6.5 on macOS Mojave
你好,我在train的时候产生了这个问题:
(CNN) hurui@hurui:~/Humanoid/train$ python train.py -c config.json
2020-03-31 16:44:56,099 epoch: 0
Exception in thread Thread-2:
Traceback (most recent call last):
File "/home/anaconda3/envs/CNN/lib/python3.6/threading.py", line 916, in _bootstrap_inner
self.run()
File "/home/anaconda3/envs/CNN/lib/python3.6/threading.py", line 864, in run
self._target(*self._args, **self._kwargs)
File "/home/Humanoid/train/loader.py", line 163, in next_batch_producer
self.load_pickles(paths_to_load)
File "/home/Humanoid/train/loader.py", line 119, in load_pickles
stacked_images = np.stack([np.zeros_like(input_data[trace_key][0][0], dtype=np.float32)] * (self.frame_num - 1) + [x[0] for x in input_data[trace_key]], axis=0)
File "/home/anaconda3/envs/CNN/lib/python3.6/site-packages/numpy/core/shape_base.py", line 415, in stack
raise ValueError('all input arrays must have the same shape')
ValueError: all input arrays must have the same shape
非常感谢!
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.