How to register sequential point clouds gathered from a walk down a hallway - point-cloud-library

For our university project we captured a .oni video while walking down a hallway. We then converted each frame of the .oni video to a .pcd file. What do you think the best way would be to stitch these cloud files together to recreate a single point cloud representing the entire captured hallway. I'm not sure if iterative closest point or feature based registration would fit this better. Any recommendations would be appreciated!

Sounds like a job for the PCL registration API. For example take a look at the "How to incrementally register pairs of clouds" tutorial. That uses ICP.
Also take a look at the other registration related tutorials.

Related

frequency analysis of sound

I record birds cries with two microphones. The records can go up to 3 hours and it is time-consuming on audacity to listen to the whole file each day. What I want is a script that takes my original file and gives me a bunch of short audio files, each containing a bird cry. With my microphones I am able to record in mp3 or wav. But the script should take only cries that have a higher frequency than nHz. This frequency represents the background sound that is fixed and that should not be saved. I don't know which language is the best for that and I have absolutly no idea how to do that.
Thank you all,
Thomas
This should be pretty easily doable in a variety of languages but Python is a decent place to start. I'll link you some relevant resources to get you started and then you can narrow your question if you run into problems.
To read your audio file in .wav format look at this documentation.
To take the data from your audio file and put it into a numpy array see this question and answer.
Here is the documentation for computing the Fourier transform of your data (to get the frequency content).
I would suggest taking a moving window and computing the Fourier transform of the data within that window and then saving the result to a file if there's significant content above your threshold frequency. The first link should have info on saving the audio file.
You can get some background on using the Fourier transform for this type of application from this Q&A and if it turns out that your problem is really difficult, I would suggest looking into some of the methods for speech detection.
For a more out-there suggestion, you could try frequency shifting your recording by adjusting the sample rate to make bird sounds resemble human speech and then use a black box tool like Googles VAD to pick out the bird calls. I'm not sure how well that would work though.
The problem of cutting up a long file into sections of interest is usually referred to as (automatic) Audio Segmentation. If you are willing to have a fixed audio clips out (say 10 seconds), you can also treat it as an Audio Classification problem.
The latter is very well studied problem, also applied to birds.
The DCASE2018 challenge had one taks about Bird Detection, and has lots of advanced methods. Basically all the best performing systems use a Constitutional Neural Network on log-scaled mel-spectrograms. A mel-spectrogram is 2D, so it basically becomes image classification. Many of the submissions are open source, so you can look at the code and play with them. Do note they are mostly focused on scoring well in a research competition, not to be practical tools for splitting a few files.
If you want to build your own model for this, I would recommend going with a Convolutional Neural Network pretrained on images, then pretrain on DCASE2018 data, then test it on your own data. That should give a very accurate system, though it will take a while to set up.

Improve a puzzle game AI using machine learning

My motivation for asking this question is that I have found an interesting problem using machine learning on a graph data set. There are papers out there on this subject. For example, "Learning from Labeled and Unlabeled Data on a Directed Graph" (Zhou, Huang, Scholkopf). However I do not have a background in artificial intelligence or machine learning so I would like to write a smaller program for a more general audience before working on anything scientific.
Several years ago I wrote a game called Solumns. It is an evil variant of the classic Sega game Columns. Inspired by bastet, it bruteforces for colour combinations disadvantageous to the player. It is hard.
I would like to improve upon its AI. I figure the game space (grid of coloured blocks, column positions, column colours) fits a graph structure better than a list of attributes. If that is the case, then this problem is similar to my research problem.
I am considering using the following high-level plan to solve this problem:
I'm thinking what would be useful is if the AI opponent could assign a fitness rating to a possible move based on more data than the number of existing squares on the board after the move. I'm thinking using a categoriser. Train on the move and all past moves, using the course of the rest of the game as a measure of success.
I am also thinking of developing a player bot that can beat the standard AI opponent. This could be useful when generating data for 1.
Use a sample of the player bot's games to build an AI that beats the strategic player. Maybe use this data for 1, too.
Write a fun AI that delegates to a possible combination of 1, 3, and the original AI, when appropriate, which I will determine using experimentation to find heuristic fudge factors.
To build the player bot, I figured I could use brute force to compute the sample space. Then use machine learning techniques such as those used in building Random Forests to create some kind of decision maker.
Building the AI opponent is where I am most perplexed.
Specific questions then:
Rating moves sounds like the kind of thing people do with chess, and although I'll admit my approach may be ignorant, there is a lot about this in literature and I can learn from that. Question is, should the player bot and AI opponent create the data sample? It sounds like I'm getting confused between different sample sets, which sounds like a recipe for bad training. Should I just play the game a bunch?
What kind of algorithm should I consider for training the player bot against the current AI?
What kind of algorithm should I consider for training an AI opponent against the player bot?
Extra info:
I am deliberately not asking if this strategy is a good fit for programming a game AI. Sure, you might be able to write a great AI more simply (after all it is already difficult to play). I want to learn about machine learning by doing something fun.
The original game was written in a mixture of racket and C. I am porting it to jruby for various reasons, likely with extensions or RPC calls to another faster language. I am not so interested in existing language-specific solutions here. I want to develop skills in this area and am not afraid to implement an algorithm for myself.
You can get the source for the original game here
I would not go for machine learning here. Look at game playing AIs.
You have an adversarial games (like Go) with two asymmetric players:
The user who places the pieces,
and the computer who chooses the pieces (instead of choosing pieces by chance).
I would probably start with Monte Carlo Tree Search.

Adequate Places API for travel app

I'm looking for a place API that can be used with a map API. Here are three APIs I've been thinking about:
- Google Maps/Places: https://developers.google.com/maps/
- Microsoft Bing: https://www.microsoft.com/maps/developers/mapapps.aspx
- Nokia Maps: http://api.maps.nokia.com/2.1.0/devguide/overview.html
They seem to be likely to give good results. The application I'm going to work on is on travel information. So we would like to use the best API for finding sightseeing, accommodations, restaurants, but we don't care about dentists, grocery stores, etc., which are not related to travel.
Which one do you guys think would be the best for our needs? (if you think of another good API that I didn't mention, make sure to let me know!)
Thank you,
J
It is difficult to give an absolute answer here because the quality of the data behind each of the APIs will vary from place to place, and what is "best" will depend on the nature of your app and the questions it solves - For example the extent of Google data (to pick one of your options) is generally perceived to be stronger in the Americas and weaker in Europe. Another example I have heard of is a Brazilian company that decided on using Nokia Maps because it had better coverage in rural areas even though it was weaker in the big cities. And of course the breadth and quality of the data may change with time.
I would guess that your best option here would be to run a simple beauty contest.
Take as a starting point the code examples from the relevant API developer sites
Bing Search
Google Search
Nokia Search
Then modify the code to obtain the same results for some of your typical use cases e.g. accommodations, restaurants then score each API according to your criteria
What sort of coverage is obtained in an area that is relevant for
you?
How easy is it to modify the code?
Do you like the way the results are presented?
How easy is it to get more detailed information?
How much does a data plan for the API cost?
Then use the score card to work out which API is the best for you.
Here is an example of difference in coverage from all three APIs for "bookshops" in Berlin
In this particular case the Nokia API returns more data, but a different result may be given if you look for say "Bookshops in Boston" - you need to decide which locations and which queries are most relevant to your application.
I think following list of APIs will be helpful to you.
http://www.programmableweb.com/news/134-travel-apis-kayak-yahoo-travel-and-hotelscombined/2012/02/28
There are about 134 APIs specifically meant for Travel App.

Dynamic Movies using Artificial Intelligence

I'm an AI Student, previously I was thinking about something, every time we guys we see a movie, the next time we the movie, it's the same thing, so those who have a knowledge of AI, such as the graph theory and so on, do you think it is feasible to create a dynamic movie, that is the first time you see it, it follows a path in the graph, the next time you see it, it follows a different path and as a result, we get a different movies, do u think this is feasible ??
It's a shame I can't remember the French researcher who's doing research on movie style cameras. While not an interactive movie as you propose, you could alter the strength and importance of each character, and it would position, pan and zoom the camera according to cinematography rules. It looked very promising.
While it would show you the same movie, you could see it in infinitely different variants in regards to camera positioning, each of which could lead to a different interpretation :)
But for your proposal, just go with some logic based planning AI. No need for learning as others says. You have a bunch of sequences, and a bunch of logic to describe how they fit together, which prerequisites they have et cetera. If the logic is good, it would always result in a meaningful film. But it'd be a hard task. It's hard just to make a linear film ;)
(There's a whole chapter in Russel and Norvig)
Where is an Intelligence in it? It looks like a bunch of ifs / switches with random.
The idea of AI is based on learning. Your AI component needs to adjust based on some external inputs, which I can't see in your description.
If the user could somehow tell your AI component that it likes / dislikes what he sees, than it will make sense. For example, you display a slideshow of photographs and the user tells you whether he likes or dislikes a photograph and you then choose future photographs based on his preference. You could learn from other user's preferences, too. That's AI.

Data Visualisation

UPDATE: I had posted this on UI.stackexchange also for views on different kinds od visualisation. I am posting this here for finding out the programming techniques and tools required to do so.
Let us have the following three sets of information
Now I want to combine all of this data and show it all together. Telling it like a story. Giving inter-relations. Showing similarities in terms, concepts etc. to get the following (Note that in the diagram below, the colored relations may not be exact, they are merely indicative of a node of information)
Situation: I need to tell somebody the relation between two or more important things through the commonness of concepts, keywords, behaviours in those things.
One way that I figured out would be to use circles for concepts.
So that all concepts connected to thing A would be connected to it and all concept related to B would be connected to it. And the common concepts would be connected to both. That way 2 things can be easily compared.
Problem: To build such a graph/visualisation manually would be cumbersome. Especially to add, arrange, update and manipulate.
Question: Is there a good way to do it. Also, Is there a tool available for doing this?
I hope this make the question much more clear. :)
Where does this data (the concepts, keywords, and relations between them etc...) come from? If it's in a database somewhere you could write soem code to generate a graphiz file then open it in a graphiz visualizer. There might be some tools out there that allow interactive editing of a graphiz graph, it looks like WebDot may and there are probably others.
How to display the hierarchical data on User Interface
You're talking about Venn diagrams. I think there should be plenty of online and offline tools that can help making these.
graphiz has been mentioned already, although that would be used more to show a flow of a system, or a treeview.
When you're talking about software development and want to display a design through diagrams, a complete diagram solution already exist as UML. And there are plenty of UMT tools that can help here. A commercial version is Altova UModel, which has some very nice features. You could probably use Use Cases as the most logical diagram type.
Also see Wikipedia for more info about use case diagrams. Reconsidering the image you've added, I do tend to consider it to be a usecase. Since UML is based on XML, it should be possible to transform your data through a stylesheet to UML, then use a random UML tool to display the diagrams.To convert your data to XML, well... If it's in Excel then exporting it to XML should not be too difficult.
Why is your sample image an Use Case? Well, you have actors (Pinguin, Koala, Tulips) and you have actions. (well, kind of actions: Cause for concern, some kind of animal, linked to movie, bites your nose off...) And finally, there are associations between the actors and the actions connecting them all in some way. Thus Data--(export)->XML--(Styleheet)->UML--(UML tool)->Diagram.
D3: Data-Driven Documents JS library

Resources