Skip to content

Instantly share code, notes, and snippets.

View Hirosaji's full-sized avatar
🍙
Working@paper company

Hiroya Kato Hirosaji

🍙
Working@paper company
View GitHub Profile
@Hirosaji
Hirosaji / NYPD_Complaint_Data_Current_YTD_July_2018.ipynb
Created July 22, 2020 15:13
Visualize dataset includes crimes reported to the New York City Police Department.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@Hirosaji
Hirosaji / .block
Last active July 9, 2020 10:09
Google Earth Engine × Mapbox - Reduction in NO2 by COVID-9
Google Earth Engine × Mapbox - Reduction in NO2 by COVID-9
license: mit
@Hirosaji
Hirosaji / gist:2a94283486137c77d1cec48837d48737
Created April 19, 2020 06:41
Route object architecture in Mapbox API
Route object
└── Route leg object
├── Banner instruction object
└── Route step object
└── Step maneuver object
└── Voice instruction object
@Hirosaji
Hirosaji / .block
Last active April 17, 2020 07:04
Mapbox - storytelling demo
Mapbox - storytelling demo
license: mit
@Hirosaji
Hirosaji / .block
Last active April 7, 2020 10:52
Mapbox GL JS - Simple Map
# Mapbox GL JS - Simple Map
license: mit
@Hirosaji
Hirosaji / .block
Last active April 7, 2020 07:29
Mapbox - helper.html in Storytelling
Mapbox - helper.html in Storytelling
license: mit
@Hirosaji
Hirosaji / .block
Last active February 25, 2020 02:18
Leaflet.js × D3.js × geojson-vt.js - Redraw Canvas Tiles Map
# Leaflet.js × D3.js × geojson-vt.js - Redraw Canvas Tiles Map
license: mit
@Hirosaji
Hirosaji / .block
Last active February 25, 2020 02:18
Leaflet.js × D3.js × geojson-vt.js - Clickeble Canvas Tiles Map
# Leaflet.js × D3.js × geojson-vt.js - Clickeble Canvas Tiles Map
license: mit
BERT_PRAMS = {
'vocab_file': '/efs/sp/vocab.txt',
'bert_config_file': '/efs/config.json',
'init_checkpoint': '/efs/model/bert_model.ckpt',
...
}
class convert_to_simlarity:
def __init__(self):
self.output = {"target": None, "texts": None}
def from_texts(self, target, texts):
self.output["target"] = target
self.output["texts"] = texts
self.output["sims"] = self.texts2similarity()
return self.output