How to train beginners on Nano

Nano is the first $99 computer that is able to run simple AI scripts. But does Nano have the ability to distinguish those scripts from one another, i.e. can Nano separate 2 scripts that have so many common features.

For example, Adam Geitgey’s “Face Recognition System” vs. Adrian Rosebrock’s “Getting started with…Nano.” I have entered both apps into my Nano, and I cannot, for the life of me, figure out how the Nano system keeps these 2 apps separate???..meaning, how do they tell one app from another? I can’t. I have taken to emailing installed script packages out of Nano, and trying to ferret out which is which and what they do.

I sense all of you laughing at me, at this point, and I admit I deserve it. But Nano offers the best opportunity for young people (and I am one of them…I am only 80) to experiment with AI, ML, CNN, etc. I want to be able to go into Nano and look at a package and say “there are the horns, and here is the tail, and here are the feet it uses to trample all over everyone.”

Can anyone at Nvidia help me with this problem?

Hi,

Since the usecase is different, the app is implemented in a separate app/source/GitHub/tutorial.
Try to follow the instruction of your interested topics, you will figure out how to execute the specified app.

Thanks.

As you know, Nano comes with the barest instructions necessary to get it up and running. It really needs more information about the following:
(1) The Jetson Nano file structure and naming conventions. Specifically, if I load code for 2 applications, what naming convention makes it plain which files go with app A and which files go with app B.
(2) How do I create a file?? Will the file appear as a folder? Where should I look for my app “app A” folder in the Jetson Nano hierarchy?
(3) Do I put sub-routine scripts for “app A” in my “app A” folder? (I know…it seems like a dumb question?)
(4) If data is accumulated as a result of running “app A,” where will the data be stored? For example, will “app A data” be stored in a database, and what will that database be called? If the answer to the previous questions are “yes,” I assume that the “app A database” will be 2-dimensional and that the partitions will be named.

Much of what you are asking is really “Linux” in nature, and not so much part of the Jetson itself. The Jetson is running the Ubuntu flavor/distribution of Linux, along with a few drivers for the specific hardware, but most of what you find on the internet for either “Linux” tutorials or “Ubuntu” tutorials will answer this with enough time.

Just the tip of answers, designed not so much to answer, but instead to show what you might be needing to search for…

The filesystem has a root starting point. Directories are a branch (what you’ve called folders). Everything starts at the root location, with the forward slash being what represents it. Subdirectories/directories also have a “/”, but then they also have names. The “cd” command goes to a folder/directory/subdirectory (you’d be using a command line terminal or shell). So to go to the root of everything, and to list it (the “ls” command):

cd /
ls

In a shell the “#” as the first character in documents usually means it is a comment and only there to tell you something which doesn’t actually do anything. There are exceptions, but if I were to continue the example above with comments:

cd /
# Examine what is there:
ls
# Ask what directory you are currently in ("present working directory"):
pwd
# To go to your home director, just use cd without a location name:
cd
pwd
# To see who the system thinks you are logged in as:
whoami
# A shortcut for home directory is also tilde, "~":
cd ~
# The name of the user which owns everything, starting at "/", and known as the administrative or
# "super" user, is "root".
# If you have a user called "me" (for example if "whoami" said "me"), then you could name that specific
# user's home directory with a "~name", and list content...but you will need "sudo" to run as super user
# for one command since it may not be your content. This looks at the "root" user's home directory:
sudo ls ~root
# Typically your GUI desktop exists in "~/Desktop/" (I add a trailing slash, which isn't mandatory,
# but makes it more obvious this is a directory and not a file):
cd ~/Desktop
ls

When you are on a command line text-only prompt like this, it means you are running a “shell”. This is just an end user application. The shell is also a programming environment if you learn shell scripting. There are different shells you can use or install, but the default is the “bash” shell (an acronym for “Bourne again shell”, the original “bsh” was the “Bourne shell”). Any search on google for “linux bash shell tutorial” will give good information. Some tutorials will be simple and teach basic use like I have shown. Others will be full blown programming tutorials.

FYI, the heart of Linux (and technically the only part of Linux install which is actually Linux) is the “kernel”. The kernel interacts with hardware through drivers and is not something the end user works directly with. When you add a driver for a camera, or develop a driver, then you are doing kernel programming. Programming outside the kernel, such as with the bash shell, is known as “user space” programming. The “shell” is called what it is because it wraps around the “kernel” like popcorn. The “shell” is text mode “look and feel”.

The GUI environment is a graphical shell. The GUI shell can run other user space applications, including the bash shell.

Shells determine how files are found for executable programs. File naming has no effect on whether a file can execute or not (there may be traditions, but a name like “.exe” does not have any true meaning, and “.exe” itself is a “Windows thing”). Some people will name their shell scripts with a “.sh” file extension, but it isn’t necessary.

If you want to see where files are searched for for execution (not for data), then this is a list of directories from the “PATH” environment variable. Each shell or environment you run in will inherit from its parent, and possibly add to the parent. This list is too long, so don’t try to read everything, but it demonstrates a way to see the environment of your current shell:

printenv

This environment variable is specific to where executable programs are searched for by default (and tutorials will tell you how to change it):

# The $ is special...this says to refer not to the name, but to what the content associated
# with the name:
echo $PATH

The colon ‘:’ between items in PATH is a delimiter or separator of independent path entries. If you see “/usr/bin”, then you can find programs there without effort since that is a location automatically searched if you simply type “ls” in. So for example:

# This tells you where the command "whoami" is actually at:
which whoami
# The default is in "/usr/bin"...in fact all of the program locations have "bin" in their names.
# To see what else is there:
cd /usr/bin
ls

Man pages are for short help on topics. The Jetsons save disk space and don’t add these by default, but if you wanted to use the disk space and restore all of the man page help, then you could do this (remember that “sudo” is to give super user/admin user authority for one command):

# Custom to Jetsons:
sudo /usr/local/sbin/unminimize

Notice that is a “full path”. It names “/” and every subdirectory along the branches. No default path (such as in $PATH) is required.

Once you have man pages, then you can get short help on anything you see in “/usr/bin”. For example, if you “cd /usr/bin”, then “ls”, then you might see “ssh” and be curious. A short help on the topic is via:

man ssh

(you can exit with the “q” key, or scroll with arrow keys up/down, but there are also other key bindings)

Topics on creating files (there are different types of files) are all over the internet. One way to create, and then delete an empty file would be as follows (assumes you are in a directory you have permission to be in…be VERY VERY careful to not name a file which already exists, or this will overwrite it and the original file will be gone):

# The "echo" command just echoes text. "Standard output" can be redirected to a file:
echo "" > deleteme.txt
ls -l deleteme.txt
# "cat" just spits out the contents of a file...if the file has binary nonsense, then it might
# disrupt your terminal:
cat deleteme.txt
# Now get rid of it:
rm deleteme.txt
ls deleteme.txt

Anyway, just search for “linux tutorial” on Google. You could add other constraints to a specific topic, e.g., a Google search for “linux bash tutorial” or “linux c programming”.

Dear Linuxdev,

Thanks for your note. I am still struggling with Linux. Fortunately, there are a lot of smart young men trying to create informal communities of of Python developers. Many of them has published apps that work, and allow rank amateurs like me to experiment.

James Noon

One issue you may run into with Python is that the interpreter version code is written for may differ from what you are using. For example, there are interpreters and programs for the Python 2.x series, and similar with the 3.x series. Some parts are interchangeable, but whole programs from one release are unlikely to work on the other release without adjustment. Even when you have both versions on the system there may need to be adjustments to tell the program where its specific version is.

To give you an example, the following searches for packages officially installed on your Ubuntu system (this is a long list):

dpkg --list

You could search for just packages with “python2” in the name:

dpkg --list "*python2*"

Or for just packages with “python3” in the name:

dpkg --list "*python3*"

Btw, you can put long lists in a “pager” to be able to scroll around in it. Just append “| less” (the joke was that “less is more”, and previously there was a less featured pager called “more”):

dpkg --list "*python3*" | less

The pager itself has some options to it, e.g., for searching.

There are a lot of little details which might cause confusion, but there are also a lot of people willing to answer questions if you post details of what is failing. For example, if your program doesn’t find your release of Python interpreter, then someone can get you the command for installing that version.