Category Archives: Uncategorized

Upgrading Gephi 0.8 to 0.9

Gephi’s API had a rather significant API changes; here are some tips for the upgrades. This nifty repo can get you started quickly: https://github.com/gephi/gephi-plugins This repo provides good examples of API usage: https://github.com/gephi/gephi-toolkit-demos API Changes AttributeColumn subGraphFitnessCol = model.getNodeTable().getColumn(FLD_SUBGRAPH_FITNESS, AttributeType.DOUBLE); -> Column … Continue reading

Posted in Uncategorized | Leave a comment

Machine Learning Book Recommendations

I am often asked to recommend books on machine learning (ML).  Here is a WIP list of my recommendations: http://www.amazon.com/gp/registry/wishlist/1TLVK1WKJF47S/  

Posted in Uncategorized | Leave a comment

Using AWS Lambda Alias with API Gateway

Using AWS lambda with specific alias through API Gateway; as described here with a command like: aws lambda add-permission –function-name arn:aws:lambda:us-east-1:xxxxxx:function:getData –source-arn arn:aws:execute-api:us-east-1:xxxxxx:t463p6g84d/*/POST/data –principal apigateway.amazonaws.com –statement-id  –action lambda:InvokeFunction Resulted in an error aws: error: argument operation: Invalid choice, valid choices are: … Continue reading

Posted in Uncategorized | Leave a comment

AWS Lambda invoking from code

You can invoke a lambda from your code (details); you’d probably want to use the AWSLambdaAsyncClient. CAUTION: you have to be very careful not to make re-cursive calls (unless that is your intention); otherwise you might get into an infinite loop. … Continue reading

Posted in Uncategorized | Leave a comment

DynamoDB: batch delete

Excerpt from my program; adapt as needed:   val client = new AmazonDynamoDBClient() val dynamo = new DynamoDB(client) val scanRequest = new ScanRequest() .withTableName(LocationRecord.TABLE_NAME) val items = client.scan(scanRequest).getItems items.grouped(25).foreach(group => { // DynamoDB: Member must have length less than or … Continue reading

Posted in Uncategorized | Leave a comment

does not map a @DynamoDBHashKey attribute; ensure a public, zero-parameter get method/field is annotated

Problem: “` Class does not map a @DynamoDBHashKey attribute; ensure a public, zero-parameter get method/field is annotated com.amazonaws.services.dynamodbv2.datamodeling.DynamoDBMappingException: Class does not map a @DynamoDBHashKey attribute; ensure a public, zero-parameter get method/field is annotated at com.amazonaws.services.dynamodbv2.datamodeling.DynamoDBMappingsRegistry$Mappings.getHashKey(DynamoDBMappingsRegistry.java:245) at com.amazonaws.services.dynamodbv2.datamodeling.DynamoDBMapper.needAutoGenerateAssignableKey(DynamoDBMapper.java:682) at com.amazonaws.services.dynamodbv2.datamodeling.DynamoDBMapper.save(DynamoDBMapper.java:708) at … Continue reading

Posted in Uncategorized | Leave a comment

AWS Lambda: extending execution time limit

Currently AWS Lambda limits execution time to 5 min.  However, in quite a few cases it is possible to overcome this limitation by simply re-invoking your function in an iterative manner.  Here are brief details. You can keep a tab … Continue reading

Posted in Uncategorized | 1 Comment

Using Google Scholar for managing your publications bibliography

Google Scholar (GS) is a very nifty tool.   However some of the features are not intuitive. Export Your Publications from your profile You can do that by clicking the checkbox (next to Title) in the header (export icon will … Continue reading

Posted in Uncategorized | Leave a comment

AWS Lambda Reduce Jar Size

AWS Lambda limits the size of jar to 50 MB. There are some things you can do to reduce the size of your jar. use [[ProGuard|http://proguard.sourceforge.net/]] ! Summary configuration: `shrink.proguard` to make fat jar: `sbt assembly` to make test jar … Continue reading

Posted in Uncategorized | Leave a comment

scala: case class: overloaded method constructor with alternatives: cannot be applied

I had a case class with overloaded constructor (needed for dynamoDB); kept getting the following error: overloaded method constructor with alternatives: cannot be applied to (Double) cause: some of the fields are without default values; hence the error in some … Continue reading

Posted in Uncategorized | Leave a comment