This file contains hidden or 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
| package jp.muziyoshiz.word2vec | |
| import org.apache.spark._ | |
| import org.apache.spark.rdd._ | |
| import org.apache.spark.SparkContext._ | |
| import org.apache.spark.mllib.feature.{Word2Vec, Word2VecModel} | |
| object Word2VecModelGenerator { | |
| def main(args: Array[String]) { |
This file contains hidden or 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
| # -*- coding: utf-8 -*- | |
| require 'json' | |
| require 'csv' | |
| JSON_FILE = 'swim_com.json' | |
| CSV_FILE = 'swim_com.csv' | |
| class Workout | |
| attr_accessor :name, :date, :id, :note, :distance, :duration, :achievement, :device, :pace, :url | |
| end |
This file contains hidden or 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
| # -*- coding: utf-8 -*- | |
| require 'anemone' | |
| version = ARGV[0] || "2.0" | |
| class ModulePage | |
| attr_accessor :category, :url, :name, :description, :is_extras, :version_added, :options | |
| def to_markdown | |
| s = "* [" |
This file contains hidden or 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
| <?xml version="1.0" encoding="UTF-8"?> | |
| <!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd"> | |
| <plist version="1.0"> | |
| <dict> | |
| <!-- job name --> | |
| <key>Label</key> | |
| <string>jp.muziyoshiz.embulk-healthplanet</string> | |
| <key>WorkingDirectory</key> | |
| <string>/Users/myoshiz/job/embulk-healthplanet</string> |
This file contains hidden or 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
| require 'rake' | |
| require 'rspec/core/rake_task' | |
| unless ENV['inventory'] | |
| print "ERROR: Inventory file must be specified by 'inventory' environment variable\n" | |
| print " e.g.) bundle exec rake inventory=./hosts spec:all\n" | |
| exit | |
| end | |
| groups = {} |
This file contains hidden or 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
| require 'rake' | |
| require 'rspec/core/rake_task' | |
| # Sample of Ansible groups and hosts | |
| # http://docs.ansible.com/ansible/intro_inventory.html | |
| groups = {} | |
| groups["webservers"] = [ "foo.example.com", "bar.example.com" ] | |
| groups["dbservers"] = [ "one.example.com", "two.example.com", "three.example.com" ] | |
| task :spec => 'spec:all' |
This file contains hidden or 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
| require 'rake' | |
| require 'rspec/core/rake_task' | |
| # Sample of Ansible groups and hosts | |
| # http://docs.ansible.com/ansible/intro_inventory.html | |
| groups = {} | |
| groups["webservers"] = [ "foo.example.com", "bar.example.com" ] | |
| groups["dbservers"] = [ "one.example.com", "two.example.com", "three.example.com" ] | |
| task :spec => 'spec:all' |
This file contains hidden or 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
| in: | |
| type: file | |
| path_prefix: /Users/myoshiz/devel/try1/csv/sample_ | |
| decoders: | |
| - {type: gzip} | |
| parser: | |
| charset: UTF-8 | |
| newline: CRLF | |
| type: csv | |
| delimiter: ',' |
This file contains hidden or 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
| module Embulk | |
| module Filter | |
| class MyappFilterPlugin < FilterPlugin | |
| Plugin.register_filter("myapp", self) | |
| def self.transaction(config, in_schema, &control) | |
| yield({}, in_schema) | |
| end |
This file contains hidden or 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
| module Embulk | |
| module Parser | |
| class LineDecoderSampleParserPlugin < ParserPlugin | |
| Plugin.register_parser("line-decoder-sample", self) | |
| def self.transaction(config, &control) | |
| # configuration code: | |
| parser_task = config.load_config(Java::LineDecoder::DecoderTask) |