I am trying to use the MIT jwi wordnet interface when working from hadoop. This interface uses a RAMDictionary Object whose constructor needs to receive a file indicating the location of the wordnet folder. I have copied this folder to hdfs, but I can't create a File object from it, only a Path.
Anyone knows how I can work around this?
It depends on what you are trying to do.
You say you are working from Hadoop. Are you trying to use Hadoop for processing the WordNet dictionary files themselves? If so, you may not need the RAMDictionary, just the parser. For example:
However, if you are processing something else and would like to use the WordNet dictionary as a tool to help you do it, then yes, this is slightly more complicated. You could: