This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
System.runFinalization(); | |
Runtime.getRuntime().gc(); | |
System.gc(); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
GC_EXPLICIT freed 22K, 50% free 2731K/5379K, external 1627K/2137K, paused 53ms | |
GC_EXTERNAL_ALLOC freed 374K, 52% free 3231K/6727K, external 2856K/2864K, paused 40ms | |
GC_EXTERNAL_ALLOC freed 93K, 51% free 3436K/6983K, external 9700K/9735K,paused 46ms //Activity called | |
GC_EXPLICIT freed 929K, 47% free 4249K/7879K, external 3665K/2137K,paused 73ms | |
GC_EXPLICIT freed 82K, 53% free 2787K/5831K, external 3625K/2137K,paused 57ms //Activity load complete |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
GC_CONCURRENT freed 731K, 49% free 3455K/6727K, external 1625K/2137K,paused 2ms+6ms | |
GC_EXPLICIT freed 5K, 37% free 5653K/8903K, external 6215K/6814K, paused85ms | |
GC_EXPLICIT freed 1730K, 43% free 5810K/10055K, external 8162K/8536K,paused 101ms | |
GC_EXPLICIT freed 0K, 43% free 5813K/10055K, external 8162K/8536K, paused65ms | |
GC_EXTERNAL_ALLOC freed <1K, 43% free 5812K/10055K, external 8162K/8536K,paused 69ms | |
GC_EXTERNAL_ALLOC freed 28K, 42% free 5904K/10055K, external 11663K/11710K, paused 71ms | |
GC_EXPLICIT freed <1K, 42% free 5911K/10119K, external 11728K/13776K,paused 62ms | |
GC_EXTERNAL_ALLOC freed 10K, 42% free 5945K/10119K, external 13765K/13776K, paused 65ms | |
GC_EXPLICIT freed 21K, 41% free 6003K/10119K, external 15295K/15855K,paused 64ms | |
GC_EXTERNAL_ALLOC freed <1K, 42% free 6014K/10247K, external 15295K/15855K, paused 66ms |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
WeakReference<Bitmap> tempbitmap = new WeakReference<Bitmap>(BitmapFactory.decodeStream(inputStream)); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public Bitmap openPhoto(Uri photoUri) throws IOException { | |
Bitmap bitmap = null; | |
Cursor cursor = getContentResolver().query(photoUri,new String[] {ContactsContract.CommonDataKinds.Photo.PHOTO },null, null, null); | |
if (cursor.moveToFirst()) { | |
byte[] buffer = cursor.getBlob(0); | |
if (buffer != null) { | |
ByteArrayInputStream istream = new ByteArrayInputStream(buffer); | |
bitmap = BitmapFactory.decodeStream(istream); | |
istream.close(); | |
return bitmap; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
try { | |
InstanceQuery query = new InstanceQuery(); | |
query.setUsername(“UserName”); //username and password to your db | |
query.setPassword(“Password”); | |
query.setQuery("select " + " C.calltype,C.phoneid,C.duration " | |
+ "from testdb.Timeline as T " | |
+ "inner join testdb.Call as C on T.timestamp=C.timestamp"); | |
// The result of this query is the table which Weka is going to //use for classification or prediction | |
Instances data = query.retrieveInstances(); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Database settings for MySQL 3.23.x, 4.x | |
# | |
# General information on database access can be found here: | |
# http://weka.wikispaces.com/Databases | |
# | |
# url: http://www.mysql.com/ | |
# jdbc: http://www.mysql.com/products/connector/j/ | |
# author: Fracpete (fracpete at waikato dot ac dot nz) | |
# version: $Revision: 5836 $ | |
# JDBC driver (comma-separated list) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# JDBC driver (comma-separated list) | |
jdbcDriver=com.mysql.jdbc.Driver | |
# database URL | |
jdbcURL=jdbc:mysql:[Your Database url here without any prefixes. eg(//yoururl:3306/testdb)] |