Is possible to censor videos automatically? - python

I'm creating a video sharing site using django, it's now using phpmotion but I decided to rewrite the script.
Users come to my site and upload spams and adult videos, i hate that. Is it possible to censor videos automatically? Using python, because i will soon remove phpmotion.
I'm pretty sure that this is impossible but, maybe you know about some way to do it automatically. Youtube censors Barclays football premier league games and occasionally some music videos, I don't know if it does that automatically but i guess not.

I don't know whether you understand German or not, but this article might be useful:
http://www.linux-magazin.de/Heft-Abo/Ausgaben/2011/07/Objekterkennung
They have done some amazing things with opencv and show how to detect naked bodies - if it's the adult content you're worrying about.

Related

Scraping data from a website with a search box

First of all I want to apologize if my question is too broad or generic, but it would really save me a lot of needlessly wasted time to get an answer to guide me in the right direction for the work I want to do. With that out of the way, here it goes.
I am trying to retrieve some publicly available data from a website, to create a dataset to work with for a Data Science project. My big issue is that the website does not have a friendly way to download it, and, from what I gathered, it also has no API. So, getting the data requires skills that I do not possess. I would love to learn how to scrape the website (the languages I am most comfortable with are Python and R), and it would add some value to my project if I did it, but I also am somewhat pressured by time constraints, and don't know if it is even possible to scrape the website, much less to learn how to do it in a few days.
The website is this one https://www.rnec.pt/pt_PT/pesquisa-de-estudos-clinicos. It has a search box, and the only option I configure is to click the banner that says "Pesquisa Avançada" and then mark the box that says "Menor de 18 anos". I then click the "Pesquisar" button in the lower-right, and the results that show up are the ones that I want to extract (either that or, if it's simpler, all the results, without checking the "Menor de 18 anos" box). In my computer, 2 results show up per page, and there are 38 pages total. Each result has some of it details in the page where the results appear but, to get the full data from each entry, one has to click "Detalhes" in the lower right of each result, which opens a display with all the data from that result. If possible, I would love to download all the data from that "Detalhes" page of each result (the data there alerady contains the fields that show up in the search result page).
Honestly, I am ready to waste a whole day manually transcribing all the data, but it would be much better to do it computationally, even it it takes me two or three days to learn and do it.
I think that, for someone with experience in web scraping, it is probably super simple to check if it is possible to download the data I described, and what is the best way to go about it (in general terms, I would research and learn it). But I really am lost when it comes to this, and just kindly want to ask for some help in showing me the way go about it (even if the answer is "it is too complicated/impossible, just do it manually"). I know that there are some Python packages for web scraping, like BeautifulSoup and Selenium, but I don't really know if either of them would be appropriate.
I am sorry if my request is not exactly a short and simple coding question, but I have to try to gather any help or guidance I can get. Thank you in advance to everyone who reads my question and a special thank you if you are able to give me some pointers.

Best way to make a multiplayer turn-by-turn online game with python back end

As a project for a friend's birthday I am trying to create an online multiplayer game which is based on this derivative of poker we play. I only really know how to code python so started with that and have managed to create the game basics and I guess it could be a good back end for the game but don't know how to get it online or as an app so my friend could actually play it with me.
Is there a way to use python code as a back end for an online game? I've read about Django and other frameworks but can't seem to get my head around how that would actually work.
The UI for the game really doesn't matter too much as long as theres some way to take multiple user inputs.
Appreciate any help and apologies if I use any wrong terminology Im self taught for the most part
You can use Django to make your game a web app and play it with you friend. There are many tutorials online to do this;
I suggest this one, it uses django and reactJS.
However, if his birthday is soon and you're in hurry, I don't recommend learning reactJS now (in case you're not already familiar with it). You can use simple django templates with html, css and javascript, wont take that much time. You can refer to Django official documentation to learn the basics of Django and then pull it off yourself.
Good luck.

How do I prove to users that something is safe?

Sorry if this seems like some simple question to lots of people. But basically I was working on some rotation calculator for a game I play - for fun. I thought why not share it with the gaming community in reddit in the form of a .exe so everyone could use it (without have to install python and made using Pyinstaller). I understand the risk of malware .. which is my problem. Short story short it got removed with the following message:
" As pointed out in the comments, alot of players are careful about what they click on. If it's not a known download they use they will report it which in turn means it gets removed."
I know this is safe, but i have no way to prove to others it is, which is where i'm stuck. What can i do about this?

scraping a subscribed website for video links

I use Kodi with add-ons such as Exodus which allow me to load episodes of my favourite TV programs etc, and I also have a subscription to horse and country to watch equine based shows but there is not a horse and country add-on to allow me to watch these on Kodi.
Is it possible for me to be able to code an add-on for Kodi (presumably in Python?) that would obtain all of the possible video links from www.horseandcountry.tv (catch up and on demand) using my log-in details and list these for me to watch.
I have a fair bit of experience coding (mostly Java, and a little Python), but have never written a Kodi add-on or done anything that scrapes video links from websites etc. I'm a first year computer science student so have a bit of understanding but not much experience!
First off, is what I am looking to do realistic and possible? and secondly, if so, would someone be able to give a very brief overview of how I would go about it and the necessary principles involved?
Your going to write a python addon, in this case probably a plugin is fitted best.
Have a look at https://github.com/Razzeee/generator-kodi for a good quickstart/boilerplate. (Let me know if you spot something wrong)
You might also want to use beautifulsoup to grab the links via python.

Fetching google's answers, and displaying them?

I'm starting a personal assistant project. I've noticed that if you type something like "How old is Obama" on Google, the first hit is a little thing that says "51 years (August 4, 1961)". This works for a lot of things, like, if you type "Who is Romney's wife" it returns "Ann Romney (m. 1969)". This is incredibly useful. How can I fetch this data and retrieve it?
Also, if nothing pops up, like saying "How much money is google worth", then scan each of the hits one by one and determines it. (I can do the determination part, I just need to know the scanning).
Can this be done using urllib2?
Have you considered wolframalpha ?
Its more helpful in doing dynamic computations based on a vast collection of built-in data, algorithms, and methods.
Also, Here is an example:
How old is Obama

Categories