Giter Site home page Giter Site logo

jigsaw-toxic-comment-classification-challenge's People

Contributors

dependabot[bot] avatar sermakarevich 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

Watchers

 avatar  avatar  avatar

jigsaw-toxic-comment-classification-challenge's Issues

parallelize_dataframe unable to resolve passed function

Running on Windows 10. I am adding the code from your original Jupyter notebook into my own, and the only other change is to redefine paths on the notebook and config.py for my own situation.

When train = parallelize_dataframe(train, process_comment) is run then the code hangs indefinitely. In the jupyter notebook console I can see that parallelize_dataframe cannot actually resolve the passed function, so nothing is actually happening:

AttributeError: Can't get attribute 'process_comment' on <module 'main' (built-in)>

Could this be a peculiarity of my environment?

UPDATE - Definitely a peculiarity of my environment:
Is it possible to define parallelize_dataframe so it copes with a Windows environment (see below)?

See:
https://stackoverflow.com/questions/37103243/multiprocessing-pool-in-jupyter-notebook-works-on-linux-but-not-windows
https://docs.python.org/2/library/multiprocessing.html#windows

Resolved by wrapping if __name__ == '__main__'

def parallelize_dataframe(df, func):
    if __name__ == '__main__':
        df_split = np.array_split(df, multiprocessing.cpu_count())
        pool = Pool(multiprocessing.cpu_count())
        df = pd.concat(pool.map(func, df_split))
        pool.close()
        pool.join()
    return df 

tensorflow requirement should be tensorflow-gpu

The requirements file lists tensorflow==1.6.0. However pip install only installed the CPU version, I had to install tensorflow-gpu to get the models to work. Consider amending the requirements file - would tensorflow-gpu==1.6.0 work?

GRU not able Build

I run into InvalidArgumentError when my notebook gets to the GRU section.

InvalidArgumentError (see above for traceback): No OpKernel was registered to support Op 'CudnnRNN' with these attrs.  Registered devices: [CPU], Registered kernels:
  <no registered kernels>

	 [[Node: bidirectional_1/CudnnRNN_1 = CudnnRNN[T=DT_FLOAT, direction="unidirectional", dropout=0, input_mode="linear_input", is_training=true, rnn_mode="gru", seed=87654321, seed2=0](bidirectional_1/transpose_2, bidirectional_1/ExpandDims_3, bidirectional_1/Const_1, bidirectional_1/concat_1)]]

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.