This is an offline application,user has to download the lab,install all the required softwares and then then run the lab.
This lab is about image processing in which user inputs a image,selects required controls,clicks on submit and then image is processed and displayed to user.
This lab uses Scialb for processing the images and python is used to call scilab and to build user interface.
- Scilab
- SIVP Toolbox
- Python2
- pip
- Kivy
- Scilab2py
- scipy
- numpy
- pygame
- OpenCV
Note: This lab works only with python2 but not python3.
Note: We strongly recommend ubuntu for running this software.Windows version is not stable as of now.
- Download the folder and make srch.sh executable(Right click on file,open properties,under permissions tab tick the option “Allow executing files as programs”)
- Double click on src.sh and click run in terminal(only for ubuntu).
- Password is required for installation.
- Approximatey 300MB of data is downloaded and all required softwares are autoamatically installed.
Note: If any problem arises in automatic installtion,then go for manual installation.
- Open terminal (Press ctrl + alt +T)
- Update your system
sudo apt-get update
- Install Python
sudo apt-get install python
Note: use python2 only.
- Install Scilab
sudo apt-get install scilab -y
- Install openCV
sudo apt-get install build-essential
sudo apt-get install cmake git libgtk2.0-dev pkg-config libavcodec-dev libavformat-dev libswscale-dev
- Install SIVP toolbox
scilab-cli -e "atomsInstall('SIVP'); exit;" -nb
- Install pip
sudo apt-get install python-pip
- Install numpy
pip install --user numpy
or
sudo apt-get install python-numpy
- Install scipy
pip install --user scipy
or
sudo apt-get install python-scipy
- Install scilab2py
pip install --user scilab2py
- Install kivy
sudo add-apt-repository ppa:kivy-team/kivy
sudo apt-get install python-kivy
- Make SIPLauncher.py executable:
- Right click on file,open properties,under permissions tab tick the option “Allow executing files as programs”
- For more help : Make program files executable
All the softwares are to be installed manually.
- Scilab
- Download and install scilab with below link.
- Scilab 5.5.2 Web site
- Note: Use scilab 5.5.2 only.
- SIVP Toolbox
- Open scilab, type the command given below and hit enter.
atomsInstall('SIVP')
- Restart scilab,then a message is displayed saying that toolbox is loaded
- Python 2.7
- Download and install python 2.7 from link below.
- Python 2.7 Web site.
- Note:
- Use Python 2.7 only.
- If python3 is installed in your system,then make sure to set envinormental variable to python2.7
- Install wheel and Pip
pip install wheel
pip install --upgrade pip wheel setuptools
- kivy
- Open Command prompt (Press Win + R, type cmd and hit enter)
- Type the below command and hit enter
cd C:\Python27\Scripts
- Note: This command works if python is installed to deafult directory,otherwise python path should be mentioned.
cd path\to\python2.7\Scripts
- Enter this command to install kivy
pip install kivy
- Enter this command to install kivy dependencies
pip install docutils pygments pypiwin32 kivy.deps.sdl2 kivy.deps.glew
pip install kivy.deps.gstreamer
- Scipy and Numpy
- Scipy and Numpy are installed using their wheels.
- Download the latest version of packages(‘cp27-cp27m’ should be present in filename .i.e for python2.7) for scipy and numpy.
- Move the downloaded packages to C:\Python27\Scripts ( path→\python2.7\Scripts if python is installed somewhere else)
- Then the packages using command below
pip install filename_of_package
- for example:
pip install numpy-1.11.3+mkl-cp27-cp27m-win_amd64.whl
- Pygame and Pillow
- Open command prompt and go to python scripts path as mentioned in process of installing kivy.
- Type these commands to install pygame and pillow
pip install pygame
pip install pillow
- Scilab2py
- Open command prompt and go to python scripts path as mentioned in process of installing kivy.
- Type this command to install Scilab2py
pip install scilab2py
- Scilab is required for this package,environmental variables for scilab is needed.See the link below to set path for scilab.
To run the experiment make SIPLauncher.py executable (Right click on file,open properties,under permissions tab tick the option “Allow executing files as programs”) and double click on SIPLauncher.py (this is for ubuntu).
To run the experiment double click on SIPLauncher.py (this is for windows).
- This is the first screen when application is opened.
- Select a experiment to proceed.
- Click on input image and select required image.
- When an image is selected,image preview is shown.
- When a raw data is selected,no image preview is shown.
- Fill all the required inputs and click on submit.
- Loadind screen is shown after submit button is clicked.
- Note: Loading time depends on the experiment and type,size of image,so plese wait patiently.
- After loading, all the output images are displayed in bottom panel.
- Click on image in bottom panel,to view it.
Note: in each experiment folder there is file named run_in_terminal_exp(experiment_number).py, run this file with python to perform experiment within terminal(No GUI).
- By defauilt, any error in scilab(while processing image) or python(error input controls) are displayed in popup as shown below.
SIVP toolbox will not loaded properly in some linux based machines. This error may occur when scilab and SIVP are installed manually. The setup file is provided with fix for this error,hence this error will not occur if it is installed through setup.
- Open scilab,the initial screen should be as shown below .i.e SIVP toolbox should be loaded properly.
- If not,or it is showing any error,then open terminal and type all these commands.
apt-get install libjpeg62
locate libtiff
cd /usr/lib/x86_64-linux-gnu/
ln -s libtiff.so.5 libtiff.so.4
Installation of all the required softwares either manually or through setup is purely system dependent.If any error are found in installation process,search the web for the solution or raise an issue in gitlab.
- One common error is found while installing python packages,use this command if necessary.
dpkg --configure -a
- Scilab:
- Python2.7:
- Scilab2py:
https://pypi.python.org/pypi/scilab2py
- kivy:
- Scipy:
- Numpy: