覚え書きブログ

Tensorflowのデバッガー

Pythonのデバッガーpdbでは、Tensorflowのsessionの中身をみることができない。。。 Tensorflowのデバッグは、Tensorflow独自のデバッガーを使う必要がある。 https://www.tensorflow.org/programmers_guide/debugger以下のように、「from tensorflow.python…

Pythonの覚え書き(デバッグ:pdb)

pythonでは、pdbモジュールを使うと簡単にデバッグができる。 pdbを下記のようにインポートし、ブレークしたいところに「pdb.set_trace()」を書いておくだけでよい。 import pdb pdb.set_trace() pythonスクリプトを普通に実行すると、以下のようにブレーク…

gstreamerの覚え書き(linkトラブル解決編)

gstreamer関連のライブラリをインストールして、以下のコマンドで動画が表示できるようになった。 gst-launch-0.10 v4l2src device=/dev/video0 ! video/x-raw-gray,bpp=8,depth=8,width=744,height=480 ! ffmpegcolorspace ! xvimagesink しかし、ROSを介し…

gitの覚え書き(commitのリセット)

間違ってコミットしてしまった場合、ワーキングディレクトリはそのままでコミットだけリセットすることができる。 > git reset --soft HEAD^ HEAD^で直近のコミットを削除できる。

gitの覚え書き(stash)

gitでpushしようとすると、remote repositoryの方が新しくて以下のようなエラーがでることがある。 > git push ... error: failed to push some refs to 'https://github.com/hhachiya/xxx' ヒント: Updates were rejected because a pushed branch tip is b…