AWS / Unix / Deep Learning

How to Remote Desktop to Ubuntu:
follow instructions at:
https://aws.amazon.com/premiumsupport/knowledge-center/connect-to-linux-desktop-from-windows/
one bit of instruction is missing in above link and that has to do with enabling RDP traffic to your server (allow a client machine to communicate with server over RDP). You will need to add the RDP rule to the security policies. Find it in AWS console.

If you see a blank gray screen when you RDP to AWS:
http://askubuntu.com/questions/603314/gray-screen-when-i-try-to-remote-desktop-to-ubuntu

How to Flatten a folder in unix (very useful – need to do this every once in a while):
http://unix.stackexchange.com/questions/52814/flattening-a-nested-directory?newreg=4fb80858719b4a8e9fae5eebac6ded3b

How to Resize images using imagemagick:
http://stackoverflow.com/questions/10802606/how-to-batch-resize-images-in-ubuntu-recursively-within-the-terminal

find . -name "*.jpg" | xargs mogrify -resize 50%

above can run for a long time if you have thousands of files in the directory. In that case use this script:

for f in `find . -name "*.jpg"`
do
    echo resizing $f ...
    mogrify -resize 50% $f
done

this will also run for same amount of time but will display messages to console as it is resizing each file

Authorizing Inbound Traffic for Your Linux Instances:
http://docs.aws.amazon.com/AWSEC2/latest/UserGuide/authorizing-access-to-an-instance.html

How do I make `ls` show file sizes in megabytes?
http://unix.stackexchange.com/questions/64148/how-do-i-make-ls-show-file-sizes-in-megabytes

To see the disk space consumed by files in a directory:
$du -shb .
http://stackoverflow.com/questions/1241801/total-size-of-the-contents-of-all-the-files-in-a-directory

To send file as email attachment:

cat errors.txt | mailx me@email.com

http://stackoverflow.com/questions/17359/how-do-i-send-a-file-as-an-email-attachment-using-linux-command-line

To copy file contents to clipboard:
http://stackoverflow.com/questions/1620018/copy-all-the-lines-to-clipboard

Logging out:
When you are done with your session, its always a good practice to end a ssh session by typing $logout rather than closing the window. Similarly if you are using RDP, don’t just close the window to end the session. Logout of RDP using the GUI and you might want to uncheck the box that says save this session for future logons.

Deep Learning:

http://neuralnetworksanddeeplearning.com/

https://www.kaggle.com/c/facial-keypoints-detection/details/deep-learning-tutorial

This entry was posted in Software. Bookmark the permalink.

Leave a comment