kong kong - 1 year ago 182
Linux Question

How to get linux command line functions for windows?

I am following caffe on this tutorial http://caffe.berkeleyvision.org/gathered/examples/mnist.html
I am using windows so I don't have the linux functions. Is there an easy way I can get linux functions ? When I run the shell script it launches bash which immediately closes. It doesnt seem to download anything

#!/usr/bin/env sh
# This scripts downloads the mnist data and unzips it.

DIR="$( cd "$(dirname "$0")" ; pwd -P )"
cd "$DIR"

echo "Downloading..."

for fname in train-images-idx3-ubyte train-labels-idx1-ubyte t10k-images-idx3-ubyte t10k-labels-idx1-ubyte
if [ ! -e $fname ]; then
echo "done"
wget --no-check-certificate http://yann.lecun.com/exdb/mnist/${fname}.gz
gunzip ${fname}.gz
echo "done"

Answer Source

You can consider installing such an environment, e.g. start with CYGWIN: https://www.cygwin.com/

Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download