
Listening for illegal logging chainsaws using TensorFlow - dgacmu
https://www.blog.google/topics/machine-learning/fight-against-illegal-deforestation-tensorflow/
======
ada1981
I love these guys! I helped advise them on their crowdfunding campaign a few
years ago. One of my favorite projects.

Hey Topher! Are you guys cross checking this with daily satellite imagery? I
met with a guy who's company gets a full HD shot of the earth every 24 hours
and they'd be happy to give you guys access to the visual data (they also
train algorithms on it to detect all sorts of activity).

Anyhow, I'll shoot you an email.

~~~
aerique
Do the shots include oceans and seas as well and would ships be visible on
those shots?

I'm asking because Sea Shepherd could not continue an anti-whaling campaign
because they were technologically overmatched:
[http://www.themercury.com.au/news/politics/sea-shepherd-
anno...](http://www.themercury.com.au/news/politics/sea-shepherd-announces-
southern-ocean-ceasefire-citing-inability-to-match-military-might-backing-
japanese-whaling-fleet/news-story/68986381d9ff802f7e2012ec4ff11b68)

~~~
tony_cannistra
Planet does not image the ocean in its entirety due to the difficulty in geo-
referencing (pre-user imagery processing pipelines use ground control points,
usually just shiny objects with a known location, to locate the image on the
earth, and this is hard in the ocean), but they do image focal regions for
purposes similar to those you mention (vessel identification + tracking). I'd
also imagine this choice has something to do with preserving satellite
operational lifespan (can turn cameras off when not being used).

[https://www.planet.com/products/open-water-
monitoring/](https://www.planet.com/products/open-water-monitoring/)

------
RainforestCx
Thanks for checking out Rainforest Connection! Seems that there are lots of
[appropriate] questions about how well this works in the forest, and how our
partners on the ground follow up on alerts. Here’s a recent intervention in
Peru that sums up the process:
[https://twitter.com/lilitjejauregui/status/97585519352188518...](https://twitter.com/lilitjejauregui/status/975855193521885186?s=21)

~~~
O_nlogn
This is a really cool application of this technology, great work! Do you have
any blog posts explaining the types of models you're using or open source
repos that one could contribute to?

(Asking as a ML/Software Engineer who's pleasantly surprised and yearning to
contribute to something like this!)

~~~
stefanRfcx
Thanks! We are a relatively small engineering team and we were mainly focused
on improving our system. This took a lot of effort and time, we just haven't
had a chance yet to think about open sourcing or blogging. Our days were
focused on coding. If there's interest in blog posts, I could write up some of
our technology. Just let me know whether there's an interest and what you'd
like to know.

~~~
tony_cannistra
I know that the US National Park Service Natural Sounds/Night Skies division
has an incredible about of environmental audio data that's begging for
automated analysis. This could be of _much_ use to them. They do analyse their
data, but it's largely been manual [1].

[1]:
[http://science.sciencemag.org/content/356/6337/531](http://science.sciencemag.org/content/356/6337/531)

~~~
stefanRfcx
That's very interesting. The Rainforest Connection system has the ability to
detect more than only chainsaws, so it could be really interesting to learn
more from the datasets; we'll look into that. Thanks so much for sharing!

------
fareesh
Where do I begin if I want to set something like this up?

As an experiment - my neighborhood in India has a problem with loud motorbikes
that are illegally modified. Hypothetically if I wanted to use this approach
(there are probably simpler ones in this specific case), where do I start?

Do I just start recording gigabytes of audio data every day and start doing
some kind of FFT on the data and manually tagging cases of loud bikes?

After that I suspect I can use one of those ML cheat sheets to figure out what
is the best model for this kind of thing and then I just send it data via the
TensorFlow library?

On the surface of it it feels like I'd be spending hours of processing time
converting the audio data and hours of manual tagging before I get anywhere
close to a solution. Is there a quicker or smarter way to go about this?

~~~
notahacker
I'd start with the end goal. Is the acoustic signal from the motorbikes likely
to be traceable to particular bikes? If so, would the local police actually be
interested in following up?

There is value in quantifying just how noisy the bikers are and for just how
long they disturb the neighbourhood, but you'll probably need the perpetrators
to be people the police are able and willing to stop to get anywhere.

~~~
fareesh
Yeah I've already spoken with the police they are down with nabbing these
folks if there's video evidence.

I could theoretically leave a camera running or simply trigger on high enough
volume but for assuming I wanted to do it this way I'm curious about the best
approach.

------
sol_remmy
5 years from now: "listening for illegal speech in city streets using
TensorFlow"

~~~
ct0
sign language will be everyone's primary language. Better yet a combination of
sign and spoken.

~~~
pbhjpbhj
Eyebrow semaphore? Hand-to-hand Morse Code?

~~~
rashkov
I’ve been thinking a bit about wearable computing and pervasive encrypted
communication. I think personal encryption could become more necessary in an
age of deep learning enabled fake video and audio. Wearable computing could
take readings from your body and environment as a sort of timestamp and
fingerprint. It could also enable an easy way to type messages to others
privately.

------
GuyPostington
If a tree falls in the forest, TensorFlow will hear it.

~~~
dzhiurgis
> Hot deals on chainsaw chains in your area, click here for 50% discount

------
crescentfresh
I'm not too familiar with ML, do you have to "train" tensorflow as to what
audio in the data is "definitely a chainsaw" and which is "definitely a
logging truck", etc etc? As in, you should keep doing this every now and then
as you get more and more data, at least in the sense of flagging false
positives (so as to unlearn that particular sound).

~~~
osipov
Yes. In the video there is a short snippet where the audio is shown as a
Fourier transformed image on the screen and a user is annotating the image of
the sound using red boxes. This is a part of the process to train the ML model
to recognize chainsaw sounds vs. other sounds.

~~~
starchand
But can it identify lyrebird's?

~~~
mongoosled
If a lyrebird is mimicking a chainsaw or truck, wouldn't that indicate the
presence of those chainsaws and trucks?

~~~
arbie
I had to look this up because I though you were jesting. Turns out Lyrebirds
can mimic nearly any complex sound:
[https://youtu.be/VjE0Kdfos4Y](https://youtu.be/VjE0Kdfos4Y)

------
Rotdhizon
This technology is really cool. My question would be, "What happens when your
AI detects chainsaws or logging trucks?". Do you contact some policy
authority, some international authority? Also, why are their cell phone towers
in the middle of the jungle? What about areas deep in the wilderness where no
cell towers exist?

~~~
RainforestCx
[https://twitter.com/lilitjejauregui/status/97585519352188518...](https://twitter.com/lilitjejauregui/status/975855193521885186?s=21)

~~~
Rotdhizon
That's for small time abuses. What happens in the case of a full blown illegal
logging operation involving a entire company? What about cases where things
get violent? It's not uncommon for mining operations in the Amazon to end with
natives getting massacred, the loggers probably not unwillingly to do that to
anyone who gets in there way. When you come across a full scale logging op, do
things get complicated?

~~~
privateprofile
Exactly. In that case they arrested a couple of poor peasants, but the
people/organizations that both financed and enabled it walk free.

Like with drug labs in the jungle, all this cool technology is great for
detection but ends up hitting a brick wall of corruption when it comes to
actually solving the problem.

------
jjxw
Had the pleasure of working with their engineering team last year as part of a
pro-bono data consulting grant that a nonprofit I work on
([http://www.deltanalytics.org/](http://www.deltanalytics.org/)) provides.

Excited to see how these systems are integrated into prevention / intervention
and other applications for these systems beyond detecting illegal logging.

------
stcredzero
How about ultra-low power microprocessors coupled with capacitors, solar
cells, and MEMS microphones, that can use a continual Fourier analysis to
identify gunshots? The internal memory could be kept so small, as to preclude
the possibility of recording someone's voice for longer than one phoneme.
These could then be sprinkled around someplace like the gang territory parts
of Oakland.

EDIT: Seems that another commenter is aware of a company doing something like
this: [http://www.shotspotter.com/company](http://www.shotspotter.com/company)

------
woweeeee

      Logging
    

Man, I must have computers on the brain. This isn't about noisy server logs at
all.

~~~
yjftsjthsd-h
...but now that you point it out, I would totally try AI log analytics.

~~~
woweeeee
Figure splunk and sumologic are weeks away from product releases, I’m sure.

Either that or it’s already one of their consultant up-sells, for professional
service add-ons, before they GA something standard.

------
rhizome
Does ShotSpotter have patents or something? It seems off that they aren't
mentioned, but they're definitely prior art for this.

Hopefully it works better for logging, which is to mean: at all.

~~~
RainforestCx
It works pretty well, as demonstrated here in an event within the last couple
of weeks in Peru:
[https://twitter.com/lilitjejauregui/status/97585519352188518...](https://twitter.com/lilitjejauregui/status/975855193521885186?s=21)

------
walrus01
> We’ve hidden modified smartphones powered with solar panels—called
> “Guardian” devices

Question, how is the electrical PV power budget vs load budget calculated for
these? Having implemented PV projects ranging in size from 300W to 30kW, I'm
very interested to know what their predicted Wh per day generated from the
solar cell is vs. what the load will consume (what's the actual load of the
cellphone, how often does it wake up every day, etc).

~~~
RainforestCx
Great question, and one that’s of particular importance in our design. Many
IoT-type systems make use of on-device data analysis in order to minimize the
most energy intensive process: data transfer. Our hardware focuses instead on
getting full audio streams up into the cloud in near-real time, continuously,
24 hrs a day. This requires an exceptional amount of energy, as well as the
ability to pool energy to continue operating at night and during poor weather.
That said, we’ve really overcompensated on energy capture and storage—we
operate under the assumption that we should be able to support 1.5 watts of
continuous power draw 24hrs a day (normally it’s closer to 50% of this). But
that means we try to be able to generate 35-40 watt-hours of solar energy for
each day (on average). This is further complicated by the shady/infrequently
lit conditions of the tree canopy. So, when direct light shows up (sometimes
for moments or minutes only) we want to be able today capture as much as
possible (high charging amperage and ample solar panels). Our batteries
(LiFePO4) must be able to support this, and not decline over 1-2 years of use
being fully discharged and recharged each day). We also designed a type of
solar array that is specifically intended for the tree canopies. If this is
interesting I’d be more than happy to elaborate more!

~~~
walrus01
That is a really good answer, and thanks for taking the time to write it up.
The difference in instantaneous wattage produced by good quality 156mm
monocrystalline Si cells is huge in direct sunlight vs shade. You can take a
modern 60-cell, 300W rated panel (STC rating) and hold a piece of cardboard a
meter away from it, to temporarily shade it, and see a huge difference. What
size of PV panel are you using for each node, and how many/what type of cells?

I'm _assuming_ that for cost reasons and economies of scale that you're using
some sort of standard off the shelf PV module that can be acquired in bulk, at
low cost, such as a 156mm poly x 54-cell module. Or maybe something a bit
smaller than that.

1.5W load x 24 hours x 31 days = 1116 Wh per month

For a typical node what is your calculated PV production in Wh per month?
Taking the 40Wh per day figure mentioned above, that's 40 * 31 = 1240Wh per
month production goal from the PV. Will of course vary with mounting location
and shading, but I'm sure you have a floor figure that you don't want to go
below, or batteries will reach a LVD threshold overnight and everything will
shut off.

I'm also making an assumption that per-node cost is somewhat of a concern in
general. For very small PV setups a decent charge controller (that can handle
up to the max of one medium sized panel) is not very expensive. Are you using
an off-the-shelf $65-75 chinese small MPPT PV charge controller with voltage
levels set up to match your LiFePo4 battery setup, or something you've
designed yourselves? something like this? [https://www.amazon.com/DROK-
Controller-Converter-Regulator-C...](https://www.amazon.com/DROK-Controller-
Converter-Regulator-Charging/dp/B073PR56R9/ref=sr_1_5?s=lawn-
garden&ie=UTF8&qid=1521856393&sr=1-5&keywords=mppt+charge+controller&dpID=518HaEXKvpL&preST=_SY300_QL70_&dpSrc=srch)

------
loceng
Are there methods to change the noise of a chainsaw, as there's money to be
made in illegal logging - they'll have the incentive if they're organized, so
it would be quiet enough or different enough to potentially sound like it's
"outside" of a protected area or not a chainsaw at all?

~~~
bourhan-rfcx
If and when they do that we will find a way to adapt and detect. The beauty of
a real-time system is that you can make changes/improvements remotely without
having to go out in the forest again and swap devices out.

In fact, the forest is a very loud place and yet we are still able to detect
the sound signature of a chainsaw.

You can hear it for yourself here:

iOS App [http://bit.ly/RFCx-iOS](http://bit.ly/RFCx-iOS)

Android App [http://bit.ly/RFCx-Android](http://bit.ly/RFCx-Android)

~~~
loceng
Thanks.

I was thinking and wondering how reasonable as a "next step" in protecting
forests to potentially require GPS tracking on all or certain types of
chainsaws - it feels like an absurd thought on its own, though it potentially
helps solve the problem.

This could then extend tracking to imagery via satellite - via geographic and
density changes being detected, knowing where the GPS-tracked and legal work
was being done, being able to then eliminate those areas from as high of
scrutiny. Perhaps the GPS tracking is then not necessary if you can accurately
compare before/after imagery, though could be a useful tool anyway for
management to know how efficiently equipment is being used, if it's at where
it should be and such.

This reminded me of a story my father once told me. I assume he heard it
because his father was part of the Ministry of Forest in Canada a long time
ago: I believe it was during a world war (not sure which one) when I could
imagine lumber would have been in constant demand. There was a bit of a trick
and literal loop-hole that truckers would use. Before being discovered there
apparently was a long route where truckers would go through without actually
dropping off their lumber - after having gone to the weigh-in point to get
paid. They'd continue to drive through the back to return another day with the
same load to get paid again; a long drive apparently but still was a money
maker..

------
ForgorPsxrd123x
Or they could legitimately be trying to make the world a better place along
with making money. I know, naive right?

~~~
John_KZ
Yeah it's pretty naive. Google trying to make the world a better place would
actually be illegal and would place the managers in jail for defrauding
investors. Google's mission is to make as much money as possible, typical
tactics include creating a good corporate image.

~~~
shaki-dora
This is a myth, mostly.

First of all: no jail. This is civil law, not criminal.

Second: it's pretty hard not to have an excuse to do anything you want if
you're the board + management. Google, and most other companies, give to
charitable organisations, for example. "Now", you'll say, "they're just doing
this for PR".

Maybe... But using the PR argument actually works perfectly fine for
_anything_ altruistic a company may do.

Unless management explicitly states that they're harming investors for the
public good, it's almost impossible to run afoul of the law. Sick pay that
exceeds the law? Important for employee retention (and PR). Match your
employees' donation to any certified charity? Important to create a community
(and PR).

~~~
triangleman
If a publicly owned company started to contribute too much money to charity,
they would certainly be subject to shareholder lawsuits and a proxy war over
management.

Sick pay is easier to do because it's related to retaining good employees.

But generally, as Milton Friedman famously wrote, "the social responsibility
of corporations is to increase their profits".

~~~
shaki-dora
"Apple donates $5 million to hurricane relief, makes it easier for customers
to donate": [http://money.cnn.com/2017/09/08/technology/apple-donation-
hu...](http://money.cnn.com/2017/09/08/technology/apple-donation-hurricane-
harvey-irma/index.html)

(just search for [<company> donates], and you'll find examples of charitable
donations for every single Fortune 500 company)

------
joshaidan
Have the creators of this project considered the privacy implications of
capturing, recording, or analyzing audio from the rainforest? What happens if
people are walking near a microphone and a conversation is picked up by the
microphones?

I realize that the audio is probably analyzed for the sound of chainsaws, and
then thrown away, but there's still the potential that such a system could be
misused. So just wondering what people think about the ethical issues related
to this technology.

~~~
beisner
Not really answering your question, but in the interest of protecting a
critical ecosystem I think some theoretical privacy loss is an acceptable
trade off. Privacy is not the be-all-end-all.

------
RainforestCx
TechCrunch just posted a slightly broader article on the project:
[https://techcrunch.com/2018/03/23/rainforest-connection-
enli...](https://techcrunch.com/2018/03/23/rainforest-connection-enlists-
machine-learning-to-listen-for-loggers-and-jaguars-in-the-amazon/)

------
aynsof
Someone more familiar with satellites can correct me, but from my
understanding you should be able to detect deforestation from real-time
satellite data. You alert on changes in the level of greenery in the images.
The indicator might trail behind detecting chainsaw noises, but it wouldn't
require the mass distribution of detector devices.

~~~
bourhan-rfcx
As Tony points out below it is often too late with satellite imagery and they
can only capture after the devastation occurs.

Our system is as real-time as it gets. In fact you can download our app right
now and listen live to the sounds of the forests:

iOS App [http://bit.ly/RFCx-iOS](http://bit.ly/RFCx-iOS)

Android App [http://bit.ly/RFCx-Android](http://bit.ly/RFCx-Android)

------
taggjefferson
Congrats Topher and team! Awesome writeup, and look forward seeing you all
soon for our next SC reunion dinner.

-All the GridCure folks

------
raisedbyninjas
They're streaming audio 24x7 all over the Amazon, but I can't get a signal in
the office hallway.

~~~
yjftsjthsd-h
Well, Amazon is already peered with major ISPs;)

------
grusel
The title is asking for attention unnecessarily since the neural network will
not be able to distinguish between "legal" and "illegal" chainsaws. It should
just say: Listening for logging chainsaws [...]

~~~
ada1981
Presumably they are listening in areas which are already protected from
logging, so any chainsaws in this area are illegal if they are cutting trees.

------
closeparen
“Listening for illegal logging...”

“Is this about GDPR?”

“... chainsaws”

“Oh.”

------
crb002
Deere Forestry and other manufactures have GPS coordinates of all major gear
in Brazil. We don't need to use acoustics.

~~~
RainforestCx
This is a super interesting tip — thank you, we were not aware of this (it is
reminiscent of tracking of shipping vessels). Do you know of where and how we
might be able to make these data available to local partners, like the Tembé
tribe, and others? Do you have any contacts at Deere Forestry? Thanks in
advance.

------
_pmf_
How about detecting fraudulent blockchain ads?

~~~
loceng
What would constitute a non-fraudulent blockchain ad?

All ICOs are all designed to be the same Ponzi-Pyramid scheme, as how they're
incentivized - which is what makes Bitcoin, Ethereum's Ether et al in the same
boat.

~~~
proofofmoon
Most ICOs are speculative but not Ponzi/pyramid schemes. They do not borrow
against previous investors' funds and they do not have referral DAGs. Do you
consider Facebook's IPO a Ponzi/pyramid scheme?

------
soVeryTired
Anyone else wonder if google's on a massive PR drive given all the privacy-
related bad press that tech has been getting recently?

~~~
bringtheaction
I don’t think so. Google is massive and people that work there have been doing
lots of different research for a very long time. OP has nothing to do with the
past days of Facebook stuff IMO.

~~~
soVeryTired
Yep, no doubt. But you can make choices about whose work you highlight to the
public.

------
LifeLiverTransp
Next step, mine the rainforrest with sound detecting landmines? Technical
solutions to social problems - any examples where this worked?

~~~
John_KZ
Exactly. Not to mention that some other guy in this thread said that in Brazil
now all forestry equipment is sold with GPS tracking, so there's literally
zero need for such a device regardless.

If they want people to stop chopping down forests they need to provide them
with a differnt, viable source of income. If I was living in deep poverty and
there was a forest near me I'd chop it down, no question about it.

~~~
LifeLiverTransp
The sole voice of reason- thank you.

This money should be invested into fusion or solar research - if energy is
cheap- somebody will find a vay to convert it into fast vat grown rainforrest-
and voila-> Unemployed drunks protesting before the automatic growthlab and
sawmill.

Its very hard to prevent behaviour thats economical. Its way easier to subvert
the economics behind that.

If you want to save nature- compress agriculture into vats. If you want to
compress agriculture into vats and buildings, you need cheap energy.

Solving at source, instead of gimick-gasms.

~~~
John_KZ
>Unemployed drunks protesting before the automatic growthlab and sawmill.

Or politicized unemployed people chopping your head off because you took their
jobs and gave nothing back. It goes both ways.

I don't think you understook what I meant.

By giving _them_ an alternative source of income, I meant the workers, not the
corporations.

~~~
LifeLiverTransp
Maybee they can get jobs as click-AI- basically providing non-savant
intelligence to AI-Projects.

But my point still stands, if growning local and fast in vats- rainforrest
wood would be no more economical viable.

No pressure on any fusion researchers- but you could really save the planet
right about now.

[https://www.straightdope.com/columns/read/3018/whatever-
happ...](https://www.straightdope.com/columns/read/3018/whatever-happened-to-
that-plan-to-grow-square-trees/)

------
John_KZ
Great, now you can't escape Google's tracking even in the middle of the
fucking jungle. Those bastards will triangulate your position from the sound
of your footsteps and send BigDog to slice you up.

~~~
ada1981
Come on now. You are worth more alive. They'll send bigdog with a video ad
display strapped to his side to "impress" you.

