Questions tagged [detection]

Detection is a general term that describes the action of finding an object, event or state during a process.

2165 questions
27
votes
4 answers

Determine if a point is inside or outside of a shape with opencv

I have images with white background and simple shapes in them (each image has one shape). I want to determine if a certain point (x,y) is inside the shape or not. How can I do that with opencv?
25
votes
4 answers

Notification of or detecting screenshot before being taken?

Is there a notification or other mechanism of being informed that the user is taking a screenshot with the home/power buttons? I've seen threads about wanting to disable the taking of screenshots, but that's not what I'm looking to do. I have a…
God of Biscuits
  • 1,312
  • 1
  • 13
  • 27
24
votes
2 answers

detecting a redirect with javascript - how?

Is there any way to detect whether a webpage is going to redirect me to another, knowing its URL? I mean the situation when you type URL in a text field and the script examines it for 3xx redirections.
burtek
  • 2,576
  • 7
  • 29
  • 37
23
votes
4 answers

How to tell if sqlite database file is valid or not

In the code below, pathToNonDatabase is the path to a simple text file, not a real sqlite database. I was hoping for sqlite3_open to detect that, but it doesn't (db is not NULL, and result is SQLITE_OK). So, how to detect that a file is not a…
apalopohapa
  • 4,983
  • 5
  • 27
  • 29
23
votes
4 answers

Use jQuery to detect whether a device can make telephone calls (supports "tel://" protocol)

In my website, I have several links like so: 218.111.2222 I want to use jQuery (or other method) to determine whether the device supports making calls / using the tel:// protocol. Does such a method…
Patrick Moore
  • 13,251
  • 5
  • 38
  • 63
21
votes
1 answer

NWPathMonitor not calling satisfied in Swift

I'm using NWPathMonitorto detect when internet connection is on and off. The method gets called when both states happens, however when the internet connection is on, the called status still is .unsatisfiedinstead of .satisfied. Here's the class that…
Andrey Solera
  • 2,311
  • 2
  • 26
  • 51
20
votes
5 answers

jQuery: detecting cmd+click / control+click

i have the options of my web application in tabs.
19
votes
3 answers

TensorFlow Object Detection API - what do the losses mean in the object detection api?

What do each for the following losses mean? (in the TensorFlow Object detection API, while training FasterRCNN based…
이양규
  • 203
  • 1
  • 2
  • 5
18
votes
4 answers

iOS / C: Algorithm to detect phonemes

I am searching for an algorithm to determine whether realtime audio input matches one of 144 given (and comfortably distinct) phoneme-pairs. Preferably the lowest level that does the job. I'm developing radical / experimental musical training…
P i
  • 29,020
  • 36
  • 159
  • 267
17
votes
6 answers

Similar code detector

I'm search for a tool that could compare source codes for similarity. We have a very trivial system right now that has huge amount of false positives and the real positives can easily get buried in them. My requirements are: reasonably small amount…
Šimon Tóth
  • 35,456
  • 20
  • 106
  • 151
16
votes
4 answers

Getting MimeType subtype with Apache tika

I'd need to get the iana.org MediaType rather than application/zip or application/x-tika-msoffice for documents like, odt, ppt, pptx, xlsx etc. If you look at mimetypes.xml there are mimeType elements composed of the iana.org mime-type and…
lisak
  • 21,611
  • 40
  • 152
  • 243
16
votes
2 answers

Apache proxy load balancing backend server failure detection

Here's my scenario (designed by my predecessor): Two Apache servers serving reverse proxy duty for a number of mixed backend web servers (Apache, IIS, Tomcat, etc.). There are some sites for which we have multiple backend web servers, and in those…
Jon Heese
  • 161
  • 1
  • 2
  • 11
15
votes
4 answers

Cycle detection in linked list with the Hare and Tortoise approach

I understand that in order to detect a cycle in a linked list I can use the Hare and Tortoise approach, which holds 2 pointers (slow and fast ones). However, after reading in wiki and other resources, I do not understand why is it guaranteed that…
Meir
  • 1,691
  • 2
  • 14
  • 15
15
votes
7 answers

Python - can I detect unicode string language code?

I'm faced with a situation where I'm reading a string of text and I need to detect the language code (en, de, fr, es, etc). Is there a simple way to do this in python?
sa125
  • 28,121
  • 38
  • 111
  • 153
15
votes
4 answers

Detecting stack overflows during runtime beforehand

I have a rather huge recursive function (also, I write in C), and while I have no doubt that the scenario where stack overflow happens is extremely unlikely, it is still possible. What I wonder is whether you can detect if stack is going to get…
J. Rickson
  • 153
  • 1
  • 5