我正在进行此api通话但未获得任何结果。当我从浏览器拨打电话并使用该imo进行搜索时,我会收到船只信息,但不会收到来自代码的电话。
<!DOCTYPE html>
<html>
<head>
</head>
<body>
<div id="pr"></div>
<script>
getInfoVessel("9146314");
function httpGetAsync(url, callback) {
var xmlHttp = new XMLHttpRequest();
xmlHttp.onreadystatechange = function() {
if (xmlHttp.readyState == 4 && xmlHttp.status == 200){
callback(xmlHttp.responseText);
}
}
xmlHttp.open("GET", url, true);
xmlHttp.send(null);
}
function getInfoVessel(IMO){
httpGetAsync('http://services.marinetraffic.com/api/exportvessel/v:5/7[herecomesthekey]/protocol:jsono/imo:9146314', function(response) {
document.getElementById('pr').innerHTML = response;
});
}
</script>
</body>
</html>
答案 0 :(得分:1)
回复良好In [63]: ar = np.array([ -20145.36, 150069, 578456.3 ])
In [64]: scores = tf.nn.softmax(ar)
In [65]: sess = tf.InteractiveSession()
In [66]: scores.eval()
Out[66]: array([ 0., 0., 1.])
,但回复Status Code:200 OK
出错。
试试这段代码:
KEY NOT FOUND