コード例 #1
0
 def testLibsvm(self):
     s = Source("../data/test.data", "csv",
                json.dumps({
                    "header": True,
                    "delimiter": ","
                }), {})
     ml = ML()
     df = ml.read_source(s)
     print(df.schema.json())
コード例 #2
0
 def testJDBC(self):
     s = Source(
         "", "jdbc",
         json.dumps({
             "url": "jdbc:mysql://10.110.17.222/insight_ml",
             "driver": "com.mysql.jdbc.Driver",
             "dbtable": "user_info",
             "user": "******",
             "password": ""
         }), {})
     ml = ML()
     df = ml.read_source(s)
     ml.compute_statistics(s, "user_name")
     print(df.schema.json())