Giter VIP home page Giter VIP logo

atis.keras's Introduction

ATIS.keras

Spoken Language Understanding(SLU)/Slot Filling in Keras.

Blog post is available here: https://chsasank.github.io/spoken-language-understanding.html

Tutorial Implements RNNs in Keras to solve the Airline Travel Information System(ATIS) dataset.

Here is an example sentence and its labels from the dataset:

Show flights from Boston to New York today
O O O B-dept O B-arr I-arr B-date

This tutorial also illustrates word embeddings.

atis.keras's People

Contributors

chsasank avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

atis.keras's Issues

Extendiing the dictionary

hi, can you give some ideas of how I can increase the words contained in the dictionary to add more cities?

Thanks!

TypeError: __init__() got an unexpected keyword argument 'input_shape'

rzai@rzai00:/prj/ATIS.keras$ python main.py
Using Theano backend.
Using gpu device 0: GeForce GTX 1080 (CNMeM is disabled)
atis.pkl
Traceback (most recent call last):
File "main.py", line 35, in
model.add(Convolution1D(64,5,border_mode='same', activation='relu'))
File "/usr/local/lib/python2.7/dist-packages/keras/models.py", line 308, in add
output_tensor = layer(self.outputs[0])
File "/usr/local/lib/python2.7/dist-packages/keras/engine/topology.py", line 514, in call
self.add_inbound_node(inbound_layers, node_indices, tensor_indices)
File "/usr/local/lib/python2.7/dist-packages/keras/engine/topology.py", line 572, in add_inbound_node
Node.create_node(self, inbound_layers, node_indices, tensor_indices)
File "/usr/local/lib/python2.7/dist-packages/keras/engine/topology.py", line 149, in create_node
output_tensors = to_list(outbound_layer.call(input_tensors[0], mask=input_masks[0]))
File "/usr/local/lib/python2.7/dist-packages/keras/layers/convolutional.py", line 158, in call
dim_ordering='tf')
File "/usr/local/lib/python2.7/dist-packages/keras/backend/theano_backend.py", line 1135, in conv2d
filter_shape=filter_shape)
File "/usr/local/lib/python2.7/dist-packages/theano/tensor/nnet/conv.py", line 149, in conv2d
imshp=imshp, kshp=kshp, nkern=nkern, bsize=bsize, **kargs)
TypeError: init() got an unexpected keyword argument 'input_shape'
rzai@rzai00:
/prj/ATIS.keras$

Ran out of input

When I execute: python main.py ,I got this error:

Using TensorFlow backend.
Traceback (most recent call last):
  File "main.py", line 19, in <module>
    train_set, valid_set, dicts = data.load.atisfull()
  File "/home/c1/gitcloned/ATIS.keras/data/load.py", line 51, in atisfull
    train_set, test_set, dicts = pickle.load(f)
EOFError: Ran out of input

How can I fix it ?
Please help me, thanks a lot!

cannot import data

Hey,
I get a ModuleNotFoundError while downloading the data.

`
import numpy as np
from data import load
train_set, valid_set, dicts = load.atisfull()

ModuleNotFoundError Traceback (most recent call last)
in ()
----> 1 train_set, valid_set, dicts = load.atisfull()

D:\mypath\atisfull_keras\ATIS.keras\data\load.py in atisfull()
49
50 try:
---> 51 train_set, test_set, dicts = pickle.load(f)
52 except UnicodeDecodeError:
53 train_set, test_set, dicts = pickle.load(f, encoding='latin1')

ModuleNotFoundError: No module named 'numpy.core.multiarray\r'
`

Is that my bad or should the \r not be there?

sysinfo:
System: 3.6.3 |Anaconda custom (64-bit)| (default, Nov 8 2017, 15:10:56) [MSC v.1900 64 bit (AMD64)]
Windows-10-10.0.16299-SP0

UnpicklingError: invalid load key, '<'.

Hi, I'm having this error when loading the data, and I can't solve it:

UnpicklingError                           Traceback (most recent call last)
<ipython-input-13-d6cdf9258128> in <module>()
      2 import data.load
      3 
----> 4 train_set, valid_set, dicts = data.load.atisfull()
      5 w2idx, labels2idx = dicts['words2idx'], dicts['labels2idx']
      6 

/home/ec2-user/tf-notebook/query_intent_detection/slotfilling/data/load.pyc in atisfull()
     49 
     50     try:
---> 51         train_set, test_set, dicts = pickle.load(f)
     52     except UnicodeDecodeError:
     53         train_set, test_set, dicts = pickle.load(f, encoding='latin1')

UnpicklingError: invalid load key, '<'.

hello, the dropbox URL has been lost

in your code:

def download_dropbox():
    ''' 
    download from drop box in the meantime
    '''
    print('Downloading data from https://www.dropbox.com/s/3lxl9jsbw0j7h8a/atis.pkl?dl=0')
    os.system('wget -O atis.pkl https://www.dropbox.com/s/3lxl9jsbw0j7h8a/atis.pkl?dl=0')

but this url has been lost.
can you provide a new link?
Thanks.

Use pre trained word2vec vector as input

I am trying to use word2vec vector as input.

this is the original input

 1     ['我', '想', '看', '电影']
 2     ['有', '没有', '美剧']
 ...
 9999  ['有', '没有', '美剧']

replace words with the vector

 1     [[word2vec size=200], [word2vec size=200], [word2vec size=200], [word2vec size=200]]
 2     [[word2vec size=200], [word2vec size=200], [word2vec size=200]]
 ...
 9999  [[word2vec size=200], [word2vec size=200], [word2vec size=200]]

pan the vectors with np.zeros.

 1     [[word2vec size=200], [word2vec size=200], [word2vec size=200], [word2vec size=200], [word2vec size=200], [word2vec size=200]]
 2     [[word2vec size=200], [word2vec size=200], [word2vec size=200], [word2vec size=200], [word2vec size=200], [word2vec size=200]]
 ....
 9999  [[word2vec size=200], [word2vec size=200], [word2vec size=200], [word2vec size=200], [word2vec size=200], [word2vec size=200]]

Then use the result as input. Is this doable? and how should I do that? Thanks a lot.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.