我在linux终端中用gdb调试ac程序,我把它拆开并运行它,然后试图找到EIP寄存器的内存地址.这就是发生的事情:
(gdb)ir eip无效的寄存器`eip'
为什么说我的eip寄存器无效?
我在我的Mac OS X上向我的.bash_profile添加了一些内容,但是它们给出了错误.现在,当我启动终端时,这是我的整个文本日志:
Last login: Thu Oct 25 23:10:03 on ttys000
dirname: illegal option -- b
usage: dirname path
-bash: /bin/naoqi-bin: No such file or directory
-bash: exec: /bin/naoqi-bin: cannot execute: No such file or directory
[Process completed]
Run Code Online (Sandbox Code Playgroud)
问题是,由于"过程完成",我无法使用终端.我如何访问.bash_profile(我无法找到如何从finder中找到),或者如何再次正常运行终端以便我可以从.bash_profile文件中获取它?
我安装了numpy和matplot并使用python 2.7正常工作,但是当我使用pip安装scipy时,我收到此错误.
numpy.distutils.npy_pkg_config.PkgNotFound: Could not find file(s) ['/usr/local/lib/python2.7/site-packages/numpy/core/lib/npy-pkg-config/npymath.ini']
----------------------------------------
Command python setup.py egg_info failed with error code 1 in /var/folders/61/dpn0d5p51z19g5vypnmh3vfh0000gn/T/pip-build/scipy
Run Code Online (Sandbox Code Playgroud) 我如何将其写为列表理解?
for i in range(len(genes)):
if compareGenes(genes[i], target) > count:
best = genes[i]
count = compareGenes(genes[i], target)
Run Code Online (Sandbox Code Playgroud) 似乎tensorflow中最棘手的部分是将张量匹配到目的地.
我得到运行时错误:TypeError:"无法将feed_dict键解释为Tensor:无法将int转换为Tensor."
我正在尝试解决XOR问题,这是我的主要设置.
i = tf.placeholder(tf.float32, shape=[None,2])
y_ = tf.placeholder(tf.float32, shape=[None,1])
inp_vec = [[1.,0.],[0.,1.],[1.,1.],[0.,0.]]
solutions = [[1.],[1.],[0.],[0.]]
with tf.Session() as sess:
sess.run( tf.initialize_all_variables() )
for i in range(1000):
sess.run(optim, feed_dict={i:inp_vec, y_:solutions})
Run Code Online (Sandbox Code Playgroud)
如果您需要查看更多或想要告诉我我能做得更好的话,这是整个代码http://pastebin.com/GqrX21vf
inp_vec是[4x2],解是[4x1].两者都应匹配占位符.自从我开始张量流以来,我一直遇到匹配问题所以我开始认为我从根本上不理解设置.对此的澄清将非常感激.
macos ×2
python ×2
disassembly ×1
eip ×1
gdb ×1
pip ×1
python-2.7 ×1
scipy ×1
tensorflow ×1
terminal ×1
x86-64 ×1