|
Completely agree with Luc.
Richard Andrew x64 wrote: is it possible to use parsing technology for broader things than just compilers?
Aren't parser technologies used for other jobs than compiler designs?
Richard Andrew x64 wrote: I've just begun studying parsing and lexical analysis, and I find it fascinating.
It is all fascinating stuff. But it takes a long time and effort to come up with a decent working parser. I am working on an open source parser to parse Malayalam[^] language text and do grammar checking and it is taking long time than I expected.
|
|
|
|
|
I would have replied earlier but I didn't have a good example, but now I came across one. Scientific chemical names. They need to be parsed (since their structure is non-trivial), but that can't be called compiling
|
|
|
|
|
|
Richard Andrew x64 wrote: I wonder if parsing algorithms could be used to make a computer understand, say, the rules of a game, or the design of a spacecraft.
Yes and no. There is always ambiguity in language. One needs to be able to reason before you can "understand" a text. We (as humans) deduce meanings, interpret a text, or even skip words. It get's worse if the text contains things like sarcasm, pictures or figure of speech.
Richard Andrew x64 wrote: In other words, if we can represent concepts by tokens that a parser can understand, is it possible to use parsing technology for broader things than just compilers?
Sounds like Protege[^]
Parsing a text is one thing. Reasoning about it's content is a step up. Understanding a (short) text[^] - is even more difficult.
The computer is mightier than the pen, the sword, and usually the programmer.
|
|
|
|
|
I have trouble with the concept of a "production" in BNF.
Take, for instance, the following BNF snippet:
D := '0' | '1' | '2' | '3' | '4' | '5' | '6' | '7' | '8' | '9'
Proper BNF terminology calls the things on the RIGHT side of the :=
"productions."
However, since the thing on the left of the := is made up of the things on the right, doesn't it make more sense to call the D the production?
|
|
|
|
|
would it help to call "D" the product, i.e. the result of the production?
Luc Pattyn [Forum Guidelines] [My Articles]
The quality and detail of your question reflects on the effectiveness of the help you are likely to get.
Show formatted code inside PRE tags, and give clear symptoms when describing a problem.
|
|
|
|
|
That might help, but that nomenclature does not appear in the literature.
It just seems like such a backwards use of the word. And when words are used in alternative ways like that, it interferes with my understanding of the material.
|
|
|
|
|
Hi,
let me try again.
IIRC the righthand side is called a "production rule", not a "production".
Does that make more sense?
Luc Pattyn [Forum Guidelines] [My Articles]
The quality and detail of your question reflects on the effectiveness of the help you are likely to get.
Show formatted code inside PRE tags, and give clear symptoms when describing a problem.
|
|
|
|
|
Oh, well, yes, that does make more sense.
I guess the paper I have been reading used a lazy abbreviation of the proper term.
That sheds a whole new light on things. Thanks.
|
|
|
|
|
hai
i need to fill the blank space with certain images of diffarent sizes.images should be well placed in the space next to previous one.
sabarikuttan
Sabari MD
Application Developer
Veloxit Info Solutions
|
|
|
|
|
But what is "well placed"? Do you mean you want to do Optimal Rectangle Packing with irregular sizes and an additional constraint on the shape of the result? (you will not like the solution..)
|
|
|
|
|
Yes my rquirement is
I have rectangular free space .
i need to fill it with images of diffarent sizes.
Sabari MD
Application Developer
Veloxit Info Solutions
|
|
|
|
|
That is known as the knapsack problem. Look it up!
Luc Pattyn [Forum Guidelines] [My Articles]
The quality and detail of your question reflects on the effectiveness of the help you are likely to get.
Show formatted code inside PRE tags, and give clear symptoms when describing a problem.
|
|
|
|
|
As Harold said, it really depends on what you mean by "well placed".
If you just treat all images as rectangles, then a greedy algorithm (see knapsack problem, as Luc suggested) surely is the simplest and fastest solution.
If you go for that, remember you should manage situations where there is no solution (for example if you want ALL images placed in your blank space: it may not be possible). You may also have to go through different placing patterns in order to find a solution, so a one-go greedy algorithm may not be sufficient.
2+2=5 for very large amounts of 2
(always loved that one hehe!)
|
|
|
|
|
Hi
i want 2 implement a project in matlab tittled as 'Fingerprint Image Quality Classification'
where we get an image and classified it as wet/oily , dry and normal image .
Can anybody like 2 share his work or help me out?
Regards
|
|
|
|
|
Can you define for me wet/oily , dry and normal image?
You have the thought that modern physics just relay on assumptions, that somehow depends on a smile of a cat, which isn’t there.( Albert Einstein)
|
|
|
|
|
wet and oily image is one in which ridges are overlapped by dark circle , give impression as black ink has been spotted on fingerprint .
Dry image is one in whcih some pixels from ridges are rubbed
normal is good quality image
|
|
|
|
|
So its been a while since I did image processing and it was not in that field.
But my first thought would be if I can great a sort of pattern for each state and then try to correlate this.
Or you could try to eliminate the finger in the image and check the rest.
Something like that.
I don't know if this is helpful, because as I said its been a while.
So good luck!
Cheers
You have the thought that modern physics just relay on assumptions, that somehow depends on a smile of a cat, which isn’t there.( Albert Einstein)
|
|
|
|
|
Hi,
I know that I should not ask a general question but I spend whole week looking for any solution and I am just fed up. I need some easy guide (I am not mathematician) for the barrel distortion correction algorithm.
Thanks in advance.
|
|
|
|
|
I suggest you read some of these hits[^].
Luc Pattyn [Forum Guidelines] [My Articles]
The quality and detail of your question reflects on the effectiveness of the help you are likely to get.
Show formatted code inside PRE tags, and give clear symptoms when describing a problem.
|
|
|
|
|
Hello all,
Am trying implement TEA in my application. So far I have been able to encrypt a table with eleven colums. But i can only decrypt three of the colums. I dont seem to understand what the problem is because even the colums have similar datatype i.e. nvarchar.
why would it chose to decrypt only three colums. Below is the code where i passed the arguement.
For Each rw As DataRow In dt.Rows
decdata = New TEA()
deRecDataFnam = decp.Decrypt(rw.Item("First Name"), ned)
deRecDataLnam = decDatalab.Decrypt(rw.Item("Last Name"), ned)
deRecDataSec = decdata.Decrypt(rw.Item("Social Security Number"), ned) --> can decrypt
deRecDataPh = decdata.Decrypt(rw.Item("Phone Number"), ned)
deRecDataCon = decdata.Decrypt(rw.Item("Contact Address"), ned)
deRecDataDOB = decdata.Decrypt(rw.Item("Date of Birth"), ned) --> can
deRecDataMar = decdata.Decrypt(rw.Item("Marital Status"), ned)
deRecDataBlud = decdata.Decrypt(rw("Blood Group"), ned)
deRecDataGeno = decdata.Decrypt(rw.Item("Genotype"), ned) --> can
deRecDataGen = decdata.Decrypt(rw("Gender"), ned)
Next
the encryption and decryption code can be found here
http://allmysocial.net/post/Tiny-Encryption-Algorithm-(TEA)-in-Visual-BasicNET.aspx[^]
I can paste the algorithm if u want me to.
Thanks a lot.
|
|
|
|
|
just guessing actually, but could it be those are the only columns that are never empty?
Luc Pattyn [Forum Guidelines] [My Articles]
The quality and detail of your question reflects on the effectiveness of the help you are likely to get.
Show formatted code inside PRE tags, and give clear symptoms when describing a problem.
|
|
|
|
|
can some good reading material or examples be suggested for implementation of a dfs to find all paths preferably c++ using linked list. books, tutorials anything...
|
|
|
|
|
Here is one of the good pdf
DFS Tutorial
Abhijit Jana | Codeproject MVP
Web Site : abhijitjana.net
Don't forget to click "Good Answer" on the post(s) that helped you.
|
|
|
|
|
this shows the depth search in action by showing the nodes you visited and non visited
http://www.cs.usask.ca/content/resources/csconcepts/1998_3/DFS/java/index.html
|
|
|
|