As it currently stands, this question is not a good fit for our Q&A format. We expect answers to be supported by facts, references, or expertise, but this question will likely solicit debate, arguments, polling, or extended discussion. If you feel that this question can be improved and possibly reopened, visit the help center for guidance.
Closed 11 years ago.
I was reading in a textbook on c++ about IOstreams, and I came across this:
Whenever you want to store information
on the computer for longer than the
running time of a program, the usual
approach is to collect the data into a
logically cohesive whole and store it
on a permanent storage medium as a
file.
(Quoted from Programming Abstractions in C++)
Is there an UNUSUAL approach to storing data?
Pushing across to a server, operating systems (experimental) that let you freeze parts of RAM etc.
This is a very vague question, and really, has no good answer.
i guess if you store it at some place in the RAM, and hope for it to be there when you run your program again, that would be an unusual way of storing :-)
Related
As it currently stands, this question is not a good fit for our Q&A format. We expect answers to be supported by facts, references, or expertise, but this question will likely solicit debate, arguments, polling, or extended discussion. If you feel that this question can be improved and possibly reopened, visit the help center for guidance.
Closed 9 years ago.
is it better to modify the file using positioning (seekg/seekp ) while it's in the hard drive
with out loading it to the RAM (into an object)
or read it as a whole into an object then treat the object (delete,modify,add...)
better "mostly speed"
The answer depends on your usecase. For one thing there are cases where you can not fit the whole file in the RAM(if it is huge). Also if you only need to perform a small change, loading the whole file will be a huge overhead.
On the other hand if you need to read/modify a huge portion of the file multiple times and it is reasonably big, loading it into the RAM will make sense and will improve the performance.
As it currently stands, this question is not a good fit for our Q&A format. We expect answers to be supported by facts, references, or expertise, but this question will likely solicit debate, arguments, polling, or extended discussion. If you feel that this question can be improved and possibly reopened, visit the help center for guidance.
Closed 9 years ago.
I am currently converting some R code into C++ code, and I need a “good” C++ Random Decision Forest implementation.
So far I found three big implementation (tmva, alglib and openCv), some “small/outdated” ones (like librf), and I need to choose one of them:
Do you guys have some good/bad experiences and/or some recommendations about those libraries (or maybe some other ones)? For example, the simplicity of use, the portability, the memory use, the speed, the readability of the error messages, the bugs(?), the comments about choices in the implementation, etc.
If you want to know, I am working with Visual Studio but my code is (and should stay) compatible with Linux. The speed and memory usage are very important for me since I will compute and keep in memory a large amount of random Forests. The code that I am developing is a machine learning algorithm for symbolic time sequences.
Thank you in advance,
As it currently stands, this question is not a good fit for our Q&A format. We expect answers to be supported by facts, references, or expertise, but this question will likely solicit debate, arguments, polling, or extended discussion. If you feel that this question can be improved and possibly reopened, visit the help center for guidance.
Closed 10 years ago.
How could I embed or associate an .exe into an ordinary file, like .jpeg or any video etc.
? I want to associate the opening of the ordinary file with the execution of an executable program.
What you're trying to do is intended not to be possible. If and when it does happen, it takes place by exploiting a flaw in the program reading the file. This might take place (this is more common when the program is written in C or C++) by storing out-of-range values in the headers and hoping the program does not validate them before using them as offsets in memory, or (this is more common in higher-level languages) by taking advantage of a logical error in some overgrown feature the format intentionally allows (like embedding javascript).
Beyond this, I think any further answer is off-topic on SO. This is not a site for getting help writing malware.
As it currently stands, this question is not a good fit for our Q&A format. We expect answers to be supported by facts, references, or expertise, but this question will likely solicit debate, arguments, polling, or extended discussion. If you feel that this question can be improved and possibly reopened, visit the help center for guidance.
Closed 11 years ago.
I think Chrome OS is based on Linux and written in C/C++. I haven't looked at the source but presumably it wouldn't be too hard to change some of the images and UI etc., but if I wanted to, for example, make it log into a proprietary account instead of Google's accounts on login, how hard would it be?
How about pulling down the source first and trying to build/install it yourself? If you feel that it's way overwhelming, then nobody can say it's easy for you.
It's hard to answer "how hard" because there's not an exact standard about "how intermediate" or "how fast can you learn".
As it currently stands, this question is not a good fit for our Q&A format. We expect answers to be supported by facts, references, or expertise, but this question will likely solicit debate, arguments, polling, or extended discussion. If you feel that this question can be improved and possibly reopened, visit the help center for guidance.
Closed 11 years ago.
Does anyone know of a really rock solid C++ library for suffix tries? Other than the one in Mummer?
Ideally, I'd like:
Some concept of concurrency.
Good caching behavior.
Permissive license.
Support for arbitrary alphabets.
Being a bioinformatician, my pick would be SeqAn (check out the sequence index section). It implements a lazy suffix tree and an enhanced suffix array (an equivalent data structure), both of which have good cache behaviour.
Having actually used and then forgotten PATL, I'd like to tuck in a link in an answer.
http://code.google.com/p/patl/
It's got a couple really distinct features, and is generally pleasant reading as well.
Most likely this is a tutorial but IMO worth reading and with source code: http://marknelson.us/1996/08/01/suffix-trees.