Mosquito classifier | Tensorflow

Researcher can use this classifier to automatically distinguish a particular type of mosquito from a large dataset
mosquitoes

Requirements

Usage

  1. Clone the project or download here

    git clone https://github.com/ultimatepritam/mosquito_classifier.git

  2. Start the docker image

    docker run -it -v ~/mosquito_classifier/:/mosquito_classifier/ gcr.io/tensorflow/tensorflow:latest-devel

  3. Run the mosq script to label the image

    python /mosquito_classifier/mosq.py <path_to_file>

Accuracy
accuracy.png

Results
resul.png

Advertisements

Cyber Attack: Wannacry 2.0 and Prevention

So thats pretty much what this ransomware is, it exploits a vulnerablility within Windows system and eventually encrypts all your files and data making your
computer completely unusuable, then it demands a handsome amount of ransom
to Decrypt your files and make your Computer usable again.

Over 2 million systems all over the world are already affected by it and of which
5% from India only.

The Indian government is trying every bit to prevent this attack. The Ministry of Electronics and Information Technology has organized a live session this morning
for awareness and prevention of this virus, they even mass mailed Indian citizens

Screenshot (811).png

HOW TO MAKE MYSELF SECURE?
This is the first question that comes to mind right now, so here is how you can do that:

Windows update MS17-010
The virus uses EternalBlue exploit, which is closed by Microsoft security update MS17-010 released in March. I recommend that you check update center for presence of such an update (by code) on your computer (for example, code for Windows 7 will be KB4012212 or KB4012215).

If updates are not installed, you can download them from official Microsoft website:

https://technet.microsoft.com/en-us/library/security/ms17-010.aspx

For older systems (Windows XP, Windows Server 2003 R2), Microsoft released special patches:

https://blogs.technet.microsoft.com/msrc/2017/05/12/customer-guidance-for-wannacrypt-attacks/

Close ports 135 and 445
To prevent penetration, block the ports 135 and 445 through which the virus penetrates (in most cases they are not used by ordinary users).

To do this, open the console with administrator rights (cmd.exe -> run as administrator). And execute in turn two commands (after each command there should be status OK).

netsh advfirewall firewall add rule dir=in action=block protocol=TCP localport=135 name="Block_TCP-135"

netsh advfirewall firewall add rule dir=in action=block protocol=TCP localport=445 name="Block_TCP-445"

Disabling SMBv1 support
The vulnerability can also be closed by completely disabling SMBv1 support. Run this command in cmd (run as administrator).

dism /online /norestart /disable-feature /featurename:SMB1Protocol


Smart stay
Apart from these technical methods I’ll additionally recommend you to Search Safe,
Surf Safe, that is for this time being don’t even browse or download from Untrusted
Websites, torrents etc. And if possible then avoid using Windows for this time being.
Dual boot a free Linux distro and you don’t have to worry about these.
Please do not open any email which has attachments with tasksche.exe
Or rather don’t download any email attachments for the time being.

WHAT TO DO IF I AM ALREADY INFECTED?

Well, thats definitely a bad news for sure but you have to take some important measures
If you find yourself infected then Do these without wasting time:

Immediately isolate the system from Network

Run cleanup tools and clean your computer of the virus, Download here 

Preserve the data even if its encrypted
So before cleaning up you might want to backup all your data in an external hdd,
Cause maybe in some days a Cure for this will be discovered and then you will be able to recover your data

If you are from India then Report the incident to CERT-In and local law enforcement agency

Send the Report to incident@cert-in.org.in

INDICATORS OF COMPROMISE

Ransomware is writing itself into a random character folder in the ‘ProgramData‘ folder with the file name of “tasksche.exe” or in ‘C:\Windows\‘ folder with the file-name “mssecsvc.exe” and “tasksche.exe“.

Ransomware is granting full access to all files by using the command:
Icacls . /grant Everyone:F /T /C /Q

Using a batch script for operations:
176641494574290.bat

use endpoint protection/antivirus solutions to detect these files and remove the same

FOR CYBER SECURITY RESEARCHERS
Hashes for Wannacry:

5bef35496fcbdbe841c82f4d1ab8b7c2
775a0631fb8229b2aa3d7621427085ad
7bf2b57f2a205768755c07f238fb32cc
7f7ccaa16fb15eb1c7399d422f8363e8
8495400f199ac77853c53b5a3f278f3e
84c82835a5d21bbcf75a61706d8ab549
86721e64ffbd69aa6944b9672bcabb6d
8dd63adb68ef053e044a5a2f46e0d2cd
b0ad5902366f860f85b892867e5b1e87
d6114ba5f10ad67a4131ab72531f02da
db349b97c37d22f5ea1d1841e3c89eb4
e372d07207b4da75b3434584cd9f3450
f529f4556a5126bba499c26d67892240

Network Connections
The malware use TOR hidden services for command and control. The list of .onion domains inside is as following:

  • gx7ekbenv2riucmf.onion
  • 57g7spgrzlojinas.onion
  • Xxlvbrloxvriy2c5.onion
  • 76jdd2ir2embyv47.onion
  • cwwnhwhlz52maqm7.onion
  • sqjolphimrr7jqw6.onion


IMPORTANT LINKS AND CONTACTS

http://www.cert-in.org.in
http://www.cyberswachhtakendra.gov.in/alerts/wannacry_ransomware.html

#FIX Ubuntu: Realtek 8723BE Weak WiFi

So, I bought my new Laptop on November 2015,  two months after my old Lenovo Z510 was stolen. And this is a hp pavillion with i5 6200U ULV Processor. Well, I couldn’t tell how much frustrating it was to downgrade from Ravaging quadcore i7 to an i5 that has only 2 cores. However, it couldnt be helped and I gotta improvise now.

Now, this laptop came with preinstalled Windows 10 but I am pretty much a Linux guy,
you see. So I needed to get any Linux distro running on my system asap.
I chose Ubuntu over any other Linux distro (2nd fav Fedora 😀 ), cause I’m very much fond of it.

I dual booted my laptop with Win10 and Ubuntu 14.0.4 LTS. It was running on top of latest Linux kernel 3.8.11 , after successfully installing Ubuntu I noticed someting,
I found that my WiFi signal is weak.

Screenshot from 2016-08-11 16-23-14.png

I was completely Stunned at this cause I was just sitting next to my router and my WiFI signal is just two bars only. Not only that it was getting disconnected often due to poor signal. I thought my WiFi driver is not updated so I quickly updated them using following commands:

$ sudo add-apt-repository ppa:hanipouspilot/rtlwifi
$ sudo apt-get update
$ sudo apt-get install rtlwifi-new-dkms linux-firmware

But it Didn’t work . It was a frustrating experience and no solutions could be found.
I thought then this might be a hardware issue so, I booted back to Windows and there
it was all acting normally . I was clueless . I searched in Ubuntu Forums but did found no suitable solution to this problem.

I reinstalled Ubuntu with a version upgrade 15.04
But the problem remained at it was. I thought this maybe some bug in Ubuntu, So
I decided to give it a try with other distros, so one by one Solus, Fedora 23, RedHat, Mint
I installed all these but got the same WEAK wifi signal in not only Ubuntu but in every Linux Distros.

I understood that the bug is in the Linux Kernel itself. So i tried to upgrade the Kernel  to latest mainline version . Even after upgrading the kernel the problem remained.

Months have passed during al these . And there was still no solution to this problem.
I subscribed to every forum concerning this problem. One day, I found something on
a forum about my wifi driver RTL8723BE . A folk named Jerry Gorland wrote some
intereseting things about this problem .

“…for my particular case (HP Stream 11-r010 Cloudbook with N3050 Celeron and HP Model No. 792204-001 30x22mm M.2 Wi-Fi card): Moving the single antenna cable from one connector to the other (as shown in the attached diagram) solved the problem. This would explain why the laptop worked only when sitting right next to the Wi-Fi router: With Linux the card is configured to use the other connector compared to Windows. Now I am two floors up from my router and connected well with Xubuntu 14.04. With Xubuntu, all the hotkeys work…”

In his case the problem seem to have solved after he moved the single antenna cable to the other connector. If you gut-open your laptop then you would probably found something like this. This is the Wireless chip (wlan) inside our laptops and as you could see in the top-left corner of the picture there are two connectors there. By default the cable is connected to port 1 . But in this case as Jerry suggested we have to change it to port 2 .

HP_Stream_11_WIFI_792204-001_30x22mm_Use_Port_1_Instead.png

Well, Jerry’s solution was risky but it was effective. People around the world were saying this is working. But too bad for me is my Laptop is still in warranty period I couldn’t just
gut-open my laptop and operate on it. I had to think of some other solution.

So, I researched a lot and learned that this may be a problem with the Driver Configuration in modprobe . Because the configuration was set up wrongly so the modules weren’t correctly loading into the OS Kernel . I reported this to Realtek  but they didn’t seem to take any notice of it. But, the good thing about Opensource community is here people help each other.

Screenshot from 2016-08-27 02-49-04.png
A FOSS developer named Larry Finger (aka lwfinger) decided to take things into own hands. And he created a new repository and rebuilted the drivers for rtl8192ce, rtl8192se, rtl8192de, rtl8188ee, rtl8192ee, rtl8723ae, rtl8723be, and rtl8821ae.

Now it was all good to go, downloaded the zip and then used simple make command to install it .

$ make
$ sudo make install

Now the problem should have been solved by now but somehow it remained . So, we figured it out that this still have the issue with the Antenna part . The hardware fixing part
was seemed impossible to avoid now. We did a last try using this command

$ sudo modprobe -rv rtl8723be
$ sudo modprobe -v rtl8723be ant_sel=2

It was an wild attempt to somehow manipulate the kernel to treat the 2nd antenna as active . And Guess what ?

IT WORKED  .

Quite miraculuosly! Did a quick scan around the networks . And it showed all networks with expected signal strength. But the setting wasn’t permanent after a reboot it’ll change back to default .

$ sudo iw dev wlp2s0 scan

But that is easy to handle . One just need to modify the modprobe configuration under root priviledge and save it as permanent.

$ sudo echo "options rtl8723be ant_sel=2" > /etc/modprobe.d/50-rtl8723be.conf

Signal strength is Excellent now! The Problem which consisted for so long a time period has now been solved. Finally : )
Screenshot from 2016-08-31 22-35-58.png

Life is all good now .

Humanity is Lost

Well, today I was travelling in train and as you probably know in India many hawkers and beggars could be seen in your train journey as free or improvised entertainment services, and sometimes the hawkers do actually come in handy but the Beggars Never .

Today, I encountered such dramatic experience that I think has had gone too far. I was sitting (not quite sitting you know the word ‘Improvise’ ) in general compartment.

When at Bolpur (Santiniketan) Station some kids got in. One girl probably 7 years old holding an infant child in one hand and some musical pebbles at other with the company of her another brother who is no more than 5 years in this planet.

They started their act (or not) as such, the infant child was crying helplessly, I looked into its eyes, it was heart-breaking sadness, and his elder sister was consoling him saying things like “Don’t cry baby, mamma is just there you see.. Don’t cry mamma is there..” (and pointing fingers accordingly ) with no absolute sign of their Mamma or Whomsoever she is.

The passengers can easily understand that who ever their Mother is, Is Either Dead or worse happened to her. And that leaves these kids totally insecure.

The act started growling, the young brother brought a toy with him. A fluffy rubbery plastic bird shaped toy with a hit sensor-ed dancing light mechanism in it.

He was hitting that toy on passenger seats and the light was twinkling and that made that infant child smile for a while. Then he put the head of that toy inside his mouth, chewing on it.

The sister took the toy from his brother and gave it to the infant and he also put it in his mouth the head of the bird was working like a nipple.

All this going on and the sister was repeatedly saying “mamma is there..mamma is here..” The brother was holding an empty stainless steel glass at other hand often biting and stretching the edges with hands and was giving creepy smiles frequently.

I was watching or rather observing this with rapt attention with both my hands resting on my lap. When Suddenly, the boy held the glass in front of me, actually touching my hands with it.

It was the time when you put some coins in that glass overwhelmed by emotions thinking about those unfortunate kids and how they’ll survive this cruel world!

I looked into his eyes and said No, I could’ve given them one rupee or two but that would have been gone in vain. Because Whosoever has sent them into this business actually wants this to happen.

The child started crying again, and nothing could stop it. I asked the sister to take him home . She didn’t answer.

They don’t even know counting to hundred, yet they were collecting money trading on human emotions risking their lives, their future, everything .

They  can get mid-day meal in any government primary school, if they are orphan then enormous clubs are there in Bolpur who would happily help them.

At the age when you are supposed to play childish games with friends, some people have thrown them in the gutter of the society. And instead learning counting to hundred they learned even more mature element of life – Lying .

Some people gave them some coins and they went to the next section repeating the same act recursively .

arv_poor_61047f1
The image is only for representation purpose and of not the ones mentioned in here.

That newborn came to our world only months ago, and just how did we Welcome him!??

Windows 10 and|vs Android Lollipop True Performance Test

Okay, Here’s a statistical experiment,

Every Computer is basically a Calculator.
And do you know how to push a calculator to its limit?

The FACTORIAL function. Obviously, there are some other methods but it is the easiest one indeed.
So, I compared the new Operating Systems like,
WINDOWS 10 and Android Lollipop with Python 3.4.3 IDLE.
Firstly I checked the Famous 65! (Ya! the limit of most of the
CASIO Calculators).Then eventually I increased the value and while in,
fact(171)
Lollipop just gave up already!
Windows 10 and Python IDLE were pretty good actually,
They just kept going. I have to admit this Windows 10 is better in terms of performance than the previous versions of Windows.
But at last in,
fact(3249)
Windows 10 gave up too.
Lollipop had just shown upto 6 decimal numbers then it summoned
the exponential function to save his ass. Windows 10 had proudly
shown upto 30 decimal numbers and then did the same.
But, on the other side Python didn’t stop at all.
As I expected.screenshot2b25285532529Operating Systems are the greatest abstractions made by the developers. Developers focus on the User Interface of an OS to make it as friendly as possible but that compromises some serious computing performance. So, as the Python IDLE actually work at hardware level, it gets to use the Quad CORE i7 Processor at its full potential. Wonder how much it scored?

Actually Python is not an abstraction, It basically shows how much
my Processor is capable of. But still for the stat lovers,
I have tested fact(1000000)
Yes! ONE MILLION . and moreover I got the result as it is, without any kinda exponential drag. See the numbers and the scroll bar in the picture. So, you guys now might have an idea of how much potential and power your Processors houses, and how less you get to use actually, because of these abstractions!!
We have to make more efficient codes in the future, till then use CLI instead of GUI for greater and richer Computation, if you already know it teach other people. Do not rely much on GUI based Operating Systems.

Modern India -A Brainless Brat

Has this just become our nature not to appreciate any Gurus or Babas ?
Or to judge everyone without knowing even if they have struggled all the way in.
Not all of them are cocksuckers you know.
Whenever The Media shows someone in the NEWS, we instantly Judge them as Frauds without thinking twice. If someone has raised the hopes of lot of the people, if so many people have found something to believe into, then he must have achieved something which so many others just failed to.
No one has faith in Laws, almost every-second-person lacks even the most trivial knowledge of how the Police works and the Society runs.
But, ask them the New Bollywood Trend, you bet they know it as their life depends on it.
And all the credit for this current scenario goes to the Media (eg: India Today, Aaj Tak) , who posts Shit intentionally with or without knowing the consequences.
.
But the situation raised some questions in my mind,

*Whats wrong with my Country?
*Where are the warm bloods, who can take DECISIONS on their OWN?

*Where are the MEN who can Actually do something other than FORWARDING  a Independence Day message to 5 WhatsApp Groups?.

*All these Selfie-Loving Media-holic TREND Stalker Spineless Creatures You Don’t deserve to call yourselves “Citizens of India”,
You don’t deserve to vote for your rights. Too much freedom has been given to you and you’re not even Worthy of it.

*Now, Who the hell am I to judge you all?
I am Pritam Mondal And atleast,
I Have My Own Personal Opinion and Conceptions. I  AM  CONSCIOUS.

Majority of the people lacks a Clear Mindset,
They just love to go with the flow without thinking of any other possibilities. And all the TV serials and Media and Movies are trying consistently to break their morals, wash their brains and use them as bots.
.
Years ago I’ve witnessed People had thrown curses to Anna Hazare without knowing or I should say understanding his motives,
People had judged Baba Ramdev, Sairam,
Not so old, Arvind Kejriwal.
.
Education is a different thing but It really hurts to see that the average IQ of this country is just around 80.
#GrowUpIndians #BePositive #SudharJaoMediaWaale #RadheMaa
#RDP

What is Life?

Life is a journey towards the end… Its a flow that proceeds through some kinda outrageous obstacles.
As for now, I’m in a train, heading home.. But who can say I’ll return?
The best I can answer is, ‘I’m coming..’. Not sure enough that I Shall, an uncertainty lies within our hearts. That Uncertainty keeps us all bound together. All the Co-passengers here are willing to reach their destiny as soon as possible.
And that huge amount of +ve energy is called The Society. And those who are waiting for us at the end of our journey, praying for us at end of our sufferings, those who care for us, so that we can reach our niche destinies safely and securely are sometimes called the fruits of Life, that is Love.
I mean to say, There is no life without danger, without uncertainty, without risks..
The fear of losing something, losing someone, the fear of never reaching our destiny make us feel alive.
Ain’t so? #ThinkOfIt

Found in a Soldier’s diary

This is a small poetry, which has been found in a Dead Soldier’s diary. I don’t know much of him, but i found this on facebook and wish to share it.
If I die In a war zone,
Box me up and send me home,
Put my Gun on my chest,
And tell my mom I did my

Best,

N Tell My Dad Not To Bow,
He Will Never Get Tension

From Me Now,

Tell My Bro Study
Perfectly,
Keys Of My Bike Will Be His

Permanently,

Tell my sis don’t be upset,
Her bro will not rise after
This Sunset,
Don’t Tell My Friends They Are
Hearties,
And start to ask for parties
Tell my Love not to cry
Cause I’m a Solider
Born to Die.
Respect our Soldiers .

The f__kin Secularism in India

People can’t be Secular.
Secularism is not a such thing, that could be poured into people’s mind with ease.
But wait, before you start judging me as a racist, I’ve to confess something.
You know Why do people need a Religion?
Its because people need a clear path to follow through his lifeline.
It gives them a steady pace in Life, a Rhythm, an Organised Way out. So that they Don’t have to find it out themselves. People just put themselves in one of the religion and done.
They start to follow the Rules and Regulations, the festivals, the Unity.
Once they get adapted with it, they can’t live without it. Gens after Gens follow the same path, and thus they grow the idea of living in a great society, where only like minded people stays. They Problem comes when they meet some other people from different community. They start judging and comparing the other ways of living.
When You are part of something, and you believe it with all your nuts, then you become possessive about it. Instead of using logic, you start growing up a blind faith.
That everything in your religion is the holiest and others are full of shits.
That everything you do in your religion is the most logical, others are full of misconceptions. Things get worse, when they start thinking it like,.. like,
Who will be the Last Man Standing??

Well, You know why i’m telling all this?
All that I’m trying to say is that,
People who chose different path of living the life, No matters if the two path meets the same end,
But as the Life is Path Integral of Faith,
You can’t force them to live together, You can’t force them to live alike, You can’t force them to be brothers.
The More You Say Secular, the Irony inside the word rings in.
Whenever someone says, He is Secular, an instant though comes to mind that, the man ain’t believe in any of the Religious Controversies.
The simple meaning of this is, The man is not a Pure Hindu, Pure Muslim, Pure Christian or Any other.
The Man isn’t showing respect to the way of life his predecessor used to follow.
The Man thinks himself as well educated, scientific minded.

But this is not true, even Einstein had said that, Science and Religion can’t live without each other.
Science and Religion are the two face of a coin.

Enough Contradiction, now whats the solution?
The solution is,
True Nationalism could only born if all the different people from different communities, be a part of a bigger Community.
The Solution is Replacing the “Secular” word from the Constitution with “INDIAN”..,
Thus, Every people could rear up their own religions, and as they are a Part of a Big One. They’ll start growing up possessiveness for this “INDIAN” -term.
Thus all the Hindu, Muslims, Christians, Sikhs, Buddhists will come under a Same Roof.

All the other countries will know them as,
Indian Hindu, Indian Muslims, Indian Christians, Indian Sikhs, Indian Buddhists.

Then and only then it’ll be possible to build a Great Society.

Thank You.