Thursday, November 5, 2015
Run java code in server&terminal
simple:
java -jar test.jar
if you have store the printout into a text, use the following command:
java -jar test.jar >log.txt
The main class is defined when the code is exported from eclipse.
question:
1. how to run different main classes in a same jar file?
2. how to define the memory usage for executing the jar?
-Xms<size>
JVM default heap size.
eg: -Xms6400K,-Xms256M
-Xmx<size>
JVM max heap size
eg: -Xmx81920K,-Xmx80M
so the command can be: java -jar test.jar >log.txt -Xms<size> -Xmx<size>
if you don't name main class when export, you can name main class flexibly.
java -cp myjar.jar MyClass
how to import extra jar package into jar file
http://www.cnblogs.com/youxin/archive/2012/06/03/2532914.html
simple ways to export jar with library
export ->runnable jar file-> launch configuration(decide which is main class, which means a jar can only have 1 main class to run ), fill the export destination(eg. a.jar)->finish
java -jar test.jar
if you have store the printout into a text, use the following command:
java -jar test.jar >log.txt
The main class is defined when the code is exported from eclipse.
question:
1. how to run different main classes in a same jar file?
2. how to define the memory usage for executing the jar?
-Xms<size>
JVM default heap size.
eg: -Xms6400K,-Xms256M
-Xmx<size>
JVM max heap size
eg: -Xmx81920K,-Xmx80M
so the command can be: java -jar test.jar >log.txt -Xms<size> -Xmx<size>
if you don't name main class when export, you can name main class flexibly.
java -cp myjar.jar MyClass
how to import extra jar package into jar file
http://www.cnblogs.com/youxin/archive/2012/06/03/2532914.html
simple ways to export jar with library
export ->runnable jar file-> launch configuration(decide which is main class, which means a jar can only have 1 main class to run ), fill the export destination(eg. a.jar)->finish
nohup java -Xms4g -Xmx4g -jar centrality.jar 8edges.txt output.txt 10 100&
Nohup notes
Nohup is a function which can help you run code even you exit your terminal. All the print out information will be saved in a nohup.out file.
Some of the terminal functions:
Some of the terminal functions:
nohup gradle run&
ps pid
exit
pgrep sleep
kill 5234
nohup sleep 200&
jobs
fg 1
sh:
echo -e "OK! \h" # -e 开启转义
Tuesday, September 1, 2015
What is a "document"?
Loosjes (1962, pp. 1-8) explained documentation in historical terms: Systematic access to written texts,
he wrote, became more difficult after the invention of printing resulted in the proliferation of texts;
scholars were increasingly obliged to delegate tasks to specialists; assembling and maintaining collections
was the field of librarianship; bibliography was concerned with the descriptions of documents; the
delegated task of creating access for scholars to the topical contents of documents, especially of parts
within printed documents and without limitation to particular collections, was documentation.
Photo of star -- Yes
Stone in river -- No
Stone in museum -- Yes
Animal in wild -- No
Animal in zoo -- Yes
Object --- Document?
Star in sky -- No
INFORMATION AS THING
Three meanings of "information" are distinguished: "Information-as-process"; "information-as-
knowledge"; and "information-as-thing", the attributive use of "information" to denote things regarded as
informative. The nature and characteristics of "information-as-thing" are discussed, using an indirect
approach ("What things are informative?"). Varieties of "information-as-thing" include data, text,
documents, objects, and events. On this view "information" includes but extends beyond communication.
Whatever information storage and retrieval systems store and retrieve is necessarily "information-as-
thing".
These three meanings of "information", along with "information processing", offer a basis for classifying disparate information-related activities (e.g. rhetoric, bibliographic retrieval, statistical analysis) and, thereby, suggest a topography for "information science".
INTANGIBLE TANGIBLE ENTITY 2. Information-as-knowledge 3. Information-as-thing Knowledge Data, document PROCESS 1. Information-as-process 4. Information processing Becoming informed Data processing
The literature on information science has concentrated narrowly on data and documents as information resources.
3. Events can, to some extent, be created or re-created. In experimental sciences, it is regarded as being
of great importance that an experiment -- an event -- be designed and described in such a way that it can
be replicated subsequently by others. Since an event cannot be stored and since accounts of the results are
no more than hearsay evidence, the feasibility of re-enacting the experiment so that the validity of the
evidence, of the information, can be verified is highly desirable.
"Information-as-thing", then, is meaningful in two senses: i) At quite specific situations and points in time an object or event may actually be informative, i.e. constitute evidence that is used in a way that affects someone's beliefs; and (ii) Since the use of evidence is predictable, albeit imperfectly, the term "information" is commonly and reasonably used to denote some population of objects to which some significant probability of being usefully informative in the future has been attributed. It is in this sense that collection development is concerned with collections of information.
Numerous definitions have been proposed for "information". One important use of "information" is to denote knowledge imparted; another is the denote the process of informing. Some leading theorists have dismissed the attributive use of "information" to refer to things that are informative. However, "information-as-thing" deserves careful examination, partly because it is the only form of information with which information systems can deal directly. People are informed not only by intentional communications, but by a wide variety of objects and events. Being "informative" is situational and it would be rash to state of any thing that it might not be informative, hence information, in some conceivable situation. Varieties of "information-as-thing" vary in their physical characteristics and so are not equally suited for storage and retrieval. There is, however, considerable scope for using representations instead.
These three meanings of "information", along with "information processing", offer a basis for classifying disparate information-related activities (e.g. rhetoric, bibliographic retrieval, statistical analysis) and, thereby, suggest a topography for "information science".
INTANGIBLE TANGIBLE ENTITY 2. Information-as-knowledge 3. Information-as-thing Knowledge Data, document PROCESS 1. Information-as-process 4. Information processing Becoming informed Data processing
The literature on information science has concentrated narrowly on data and documents as information resources.
we find the evidence of events is used in three different
ways:
1. Objects, which can be collected or represented, may exist as evidence associated with events: bloodstains on the carpet, perhaps, or a footprint in the sand;
2. There may well be representations of the event itself: photos, newspaper reports, memoirs. Such documents can be stored and retrieved; and, also,
1. Objects, which can be collected or represented, may exist as evidence associated with events: bloodstains on the carpet, perhaps, or a footprint in the sand;
2. There may well be representations of the event itself: photos, newspaper reports, memoirs. Such documents can be stored and retrieved; and, also,
"Information-as-thing", then, is meaningful in two senses: i) At quite specific situations and points in time an object or event may actually be informative, i.e. constitute evidence that is used in a way that affects someone's beliefs; and (ii) Since the use of evidence is predictable, albeit imperfectly, the term "information" is commonly and reasonably used to denote some population of objects to which some significant probability of being usefully informative in the future has been attributed. It is in this sense that collection development is concerned with collections of information.
Numerous definitions have been proposed for "information". One important use of "information" is to denote knowledge imparted; another is the denote the process of informing. Some leading theorists have dismissed the attributive use of "information" to refer to things that are informative. However, "information-as-thing" deserves careful examination, partly because it is the only form of information with which information systems can deal directly. People are informed not only by intentional communications, but by a wide variety of objects and events. Being "informative" is situational and it would be rash to state of any thing that it might not be informative, hence information, in some conceivable situation. Varieties of "information-as-thing" vary in their physical characteristics and so are not equally suited for storage and retrieval. There is, however, considerable scope for using representations instead.
The Role of Facts in Paul Otlet’s Modernist Project of Documentation
Otlet’s writing is marked by
its extraordinary energy. His muscular and tireless prose powers a huge machine,
a vast assemblage of interconnected parts operating on multiple strata according
to precisely articulated scales.
hyper-modernist energy that provokes the question of this chapter: how are we to understand the co-ordination and organization of the vectors assembled and animated in Otlet’s project of documentation? To use a mathematical trope, what is the singularity that organizes this vector field?
To understand Otlet on facts, it is useful to start with his distinction between natural and social science. The former builds a ‘great monument’ through disciplined,collective work. For natural scientists, ‘speculation and interpretation are secondary’, whereas ‘the social sciences are seen ... not as one discipline ... but as a gathering of personal opinions’ (11).
science is built upon facts: ‘The results of the natural sciences are grounded in millions of carefully observed, analysed, and catalogued facts. These facts have subsequently been integrated into sequences and the combination of these sequences has naturally led to the enunciation of laws, partial at first, general later, from which the most powerful and indestructible synthesis that has ever been made now seems possible’ (11).
The creation of documents in such a way that each item of information has its own identity
A fact can be fully revealed to the consciousness of a reader only when the ‘item of information’ that refers to that fact is constructed and organized in such a way, as Rayward put it, ‘that each item of information has its own identity.’ If the identity of the item of information is somehow compromised, so is the revelation of the fact.
hyper-modernist energy that provokes the question of this chapter: how are we to understand the co-ordination and organization of the vectors assembled and animated in Otlet’s project of documentation? To use a mathematical trope, what is the singularity that organizes this vector field?
To understand Otlet on facts, it is useful to start with his distinction between natural and social science. The former builds a ‘great monument’ through disciplined,collective work. For natural scientists, ‘speculation and interpretation are secondary’, whereas ‘the social sciences are seen ... not as one discipline ... but as a gathering of personal opinions’ (11).
science is built upon facts: ‘The results of the natural sciences are grounded in millions of carefully observed, analysed, and catalogued facts. These facts have subsequently been integrated into sequences and the combination of these sequences has naturally led to the enunciation of laws, partial at first, general later, from which the most powerful and indestructible synthesis that has ever been made now seems possible’ (11).
The creation of documents in such a way that each item of information has its own identity
A fact can be fully revealed to the consciousness of a reader only when the ‘item of information’ that refers to that fact is constructed and organized in such a way, as Rayward put it, ‘that each item of information has its own identity.’ If the identity of the item of information is somehow compromised, so is the revelation of the fact.
The application of the monographic principle does not complete the documentation
of facts
The results of the natural sciences are grounded in millions of carefully observed,
analysed, and catalogued facts. These facts have subsequently been integrated into
sequences and the combination of these sequences has naturally led to the enunciation
of laws
trimmed stone
trimmed stone
Subscribe to:
Posts (Atom)