Latest news about Bitcoin and all cryptocurrencies. Your daily crypto news habit.
There have been many versions of the TASS computer vision projects over the years, one being a version built on a Raspberry Pi 3 using a program based on the Tensorflow Inception V3 transfer learning example.
The Colfax TASS Trainer replicates the transfer learning side of the original program and is trained on the Intel Nervana AI HPC Cluster (Colfax Cluster).
Access to Intel’s Ai DevCloud is free, just register on the Colfax website and you will get free access to the cloud within 48 hours.
Python Versions
- Python 3 (Intel, 2018 update 1)
Software requirements
- Intel Optimized TensorFlow (1.3.1)
Hardware requirements
- Access to the Intel Nervana AI HPC Cluster (Colfax Cluster)
Cloning The Repo
You will need to clone this repository to a location on your development terminal. Navigate to the directory you would like to download it to and issue the following commands.
$ git clone https://github.com/TechBubbleTechnologies/IoT-JumpWay-Intel-Examples.git
Once you have the repo, you will need to find the files in this folder located in this location
Install Requirements
Everything for this tutorial is already provided on Colfax.
Login To Colfax
Login to your Colfax Notebook area by following this link.
Upload Structure To Colfax
Once you have completed the steps above, it is time to login to Colfax and upload the structure described above. You need to upload all of the files shown in the screen shot below, with exception to the README.
Training & Testing Data
You can train and test this example without finding any additional training and testing data, but if you would like to add your own classes you will find the training data in the training/human directory.
The test data provided (Collected from Google) has two classes, 1 and 2, these folders represent Darth Vader and Yoda, in these directories (classes) are 30 images of each character, directory 1 represents Darth and directory 2 represents Yoda.
You can name these directories what you like, the name of the directory will be used in the predictions, so if the program detects Darth in an image it will return 1 as the highest prediction.
You can add as many as classes as you like, each class will slow the training down. Each class should have no less than 30 images, generally any more than 25 but less than 30 will crash the script with devision by 0 right at the end of the training process.
Start The Training
Now it is time to start the training, head on over to Colfax TASS Trainer notebook on Colfax. You do not need to execute any of the code blocks except for the first until you get to “Create training job”, here you can begin to execute the blocks of code following the guide which will submit a job to train TASS on the Colfax Clusters.
Testing The Trained Model
Now time for the crunch, again, you do not need to find any additional training to test this program, but if you do want to you can add more images to the model/testing directory. The testing data provided for out of the box use of this tutorial include 2 images of Darth, 2 of Yoda, and 2 of a very handsome guy ;)
Head on over to Colfax TASS Trainer Inference notebook on Colfax. You do not need to execute any of the code blocks except for the first until you get to “Create testing job”, here you can begin to execute the blocks of code following the guide which will submit a job to test TASS on the Colfax Clusters.
The output for me was as follows:
TESTING FACIAL REC
FILE: Darth1.jpg 1 (score = 0.99834) 2 (score = 0.00164)
PROVIDED IMAGE: Darth1.jpg OBJECT DETECTED: 1 CONFIDENCE: 0.998343
FILE: Darth2.jpg 1 (score = 0.99692) 2 (score = 0.00311) PROVIDED IMAGE: Darth2.jpg OBJECT DETECTED: 1 CONFIDENCE: 0.996923
FILE: Yoda2.jpg 2 (score = 0.99710) 1 (score = 0.00293) PROVIDED IMAGE: Yoda2.jpg OBJECT DETECTED: 2 CONFIDENCE: 0.997104
FILE: Yoda1.jpg 2 (score = 0.99535) 1 (score = 0.00465)
FILE: VeryHansomeGuy.jpg 2 (score = 0.72019) 1 (score = 0.27821) FILE: VeryHansomeGuy2.jpg 2 (score = 0.59470) 1 (score = 0.40845)
COMPLETED TESTING FACIAL RECOGNITION
This means that Darth was identified in each image, Yoda in 1 and the program successfully identified me as an unknown person.
Open Set Recognition Issue
Taken from Walter J. Scheirer’s website:
“Both recognition and classification are common terms in computer vision. What is the difference? In classification, one assumes there is a given set of classes between which we must discriminate. For recognition, we assume there are some classes we can recognize in a much larger space of things we do not recognize. A motivating question for our work here is: What is the general object recognition problem? This question, of course, is a central theme in vision. How one should approach multi-class recognition is still an open issue. Should it be performed as a series of binary classifications, or by detection, where a search is performed for each of the possible classes? What happens when some classes are ill-sampled, not sampled at all or undefined?
The general term recognition suggests that the representation can handle different patterns often defined by discriminating features. It also suggests that the patterns to be recognized will be in general settings, visually mixed with many classes. For some problems, however, we do not need, and often cannot have, knowledge of the entire set of possible classes. For instance, in a recognition application for biologists, a single species of fish might be of interest. However, the classifier must consider the set of all other possible objects in relevant settings as potential negatives. Similarly, verification problems for security-oriented face matching constrain the target of interest to a single claimed identity, while considering the set of all other possible people as potential impostors. In addressing general object recognition, there is a finite set of known objects in myriad unknown objects, combinations and configurations — labeling something new, novel or unknown should always be a valid outcome. This leads to what is sometimes called “open set” recognition, in comparison to systems that make closed world assumptions or use “closed set” evaluation.”
Both the Object & Facial recognition features of InceptionFlow are vulnerable to the Open Set Recognition issue, however it appears that object recognition is more realistic with its confidence than facial recognition is and it may be possible to fine tune the network / training data for facial recognition to attempt to improve this.
Intel® Nervana AI / Colfax TASS Trainer Bugs/Issues
Please feel free to create issues for bugs and general issues you come across whilst using the Intel® Nervana AI / Colfax TASS Trainer example. You may also use the issues area to ask for general help whilst using the IoT JumpWay Intel® Examples in your IoT projects.
Intel® Nervana AI / Colfax TASS Trainer Contributors
Originally published at iot.techbubbletechnologies.com.
IoT JumpWay Intel® Nervana AI / Colfax TASS Trainer was originally published in Hacker Noon on Medium, where people are continuing the conversation by highlighting and responding to this story.
Disclaimer
The views and opinions expressed in this article are solely those of the authors and do not reflect the views of Bitcoin Insider. Every investment and trading move involves risk - this is especially true for cryptocurrencies given their volatility. We strongly advise our readers to conduct their own research when making a decision.