Repository: pykeen/pykeen
Issue: "FileNotFoundError: [WinError 2] The system cannot find the file specified" During Link Prediction
Root cause: Documentation Deficiency

**Describe the bug**
I recently have tried to install and use pykeen, but I have found that it is not working on my system. When running code from the tutorials, I get the error "FileNotFoundError: [WinError 2] The system cannot find the file specified".

**To Reproduce**
The code I am running, in a file named test.py, is shown below:
```python
from pykeen.pipeline import pipeline
from pykeen.models import TransE
from pykeen.datasets import Nations

pipeline_result = pipeline(
    dataset=Nations,
    model=TransE,
)

model = pipeline_result.model

print(model)

# Predict tails
predicted_tails_df = model.get_tail_prediction_df('brazil', 'intergovorgs')

# Predict relations
predicted_relations_df = model.get_relation_prediction_df('brazil', 'uk')

# Predict heads
predicted_heads_df = model.get_head_prediction_df('conferences', 'brazil')

# Score all triples (memory intensive)
predictions_df = model.get_all_prediction_df()

# Score top K triples
predictions_df = model.get_all_prediction_df(k=150)

# save the model
pipeline_result.save_to_directory('nations_transe')

```

I attempted to install pykeen in an isolated venv as so:
```console
python -m venv env
./env/Scripts/activate
pip install pykeen
pip install torch
python test.py
```

Which resulted in a dependency error as shown below.
```python-traceback
Traceback (most recent call last):
  File ".\test.py", line 1, in <module>
    from pykeen.pipeline import pipeline        
  File "C:\Users\...\env\lib\site-packages\pykeen\pipeline.py", line 183, in <module>
    from .datasets import get_dataset
  File "C:\Users\...\env\lib\site-packages\pykeen\datasets\__init__.py", line 64, in <module>
    _DATASETS: Set[Type[Dataset]] = {
  File "C:\Users\...\env\lib\site-packages\pykeen\datasets\__init__.py", line 65, in <setcomp>
    entry.load()
  File "C:\Users\...\env\lib\site-packages\pkg_resources\__init__.py", line 2460, in load
    self.require(*args, **kwargs)
  File "C:\Users\...\env\lib\site-packages\pkg_resources\__init__.py", line 2483, in require
    items = working_set.resolve(reqs, env, installer, extras=self.extras)
  File "C:\Users\...\env\lib\site-packages\pkg_resources\__init__.py", line 790, in resolve
    raise VersionConflict(dist, req).with_context(dependent_req)
pkg_resources.ContextualVersionConflict: (numpy 
1.20.0 (c:\users\...\env\lib\site-packages), Requirement.parse('numpy<1.20.0'), {'cmaes'})
```

I was able to resolve the above error by installing an older version of numpy. 
```console
pip uninstall numpy
pip install numpy<1.20.0
python test.py
```

However, after doing this, I received another error, whose trace is shown below:
```python-traceback
No random seed is specified. Setting to 3145316483.
No cuda devices were available. The model runs on CPU
Training epochs on cpu: 100%|█| 5/5 [00:00<00:0 
INFO:pykeen.evaluation.evaluator:Currently automatic memory optimization only supports GPUs, but you're using a CPU. Therefore, the batch_size will be set to the default value.
INFO:pykeen.evaluation.evaluator:No evaluation batch_size provided. Setting batch_size to '32'. 
Evaluating on cpu: 100%|█| 201/201 [00:00<00:00 
INFO:pykeen.evaluation.evaluator:Evaluation took 0.03s seconds
Traceback (most recent call last):
  File ".\test.py", line 5, in <module>
    pipeline_result = pipeline(
  File "C:\Users\...\env\lib\site-packages\pykeen\pipeline.py", line 1069, in pipeline
    return PipelineResult(
  File "<string>", line 13, in __init__
  File "C:\Users\...\env\lib\site-packages\pykeen\version.py", line 26, in get_git_hash
    ret = check_output(  # noqa: S603,S607      
  File "C:\Users\username\AppData\Local\Programs\Python\Python38\lib\subprocess.py", line 411, in check_output
    return run(*popenargs, stdout=PIPE, timeout=timeout, check=True,
  File "C:\Users\username\AppData\Local\Programs\Python\Python38\lib\subprocess.py", line 489, in run
    with Popen(*popenargs, **kwargs) as process:  File "C:\Users\username\AppData\Local\Programs\Python\Python38\lib\subprocess.py", line 854, in __init__
    self._execute_child(args, executable, preexec_fn, close_fds,
  File "C:\Users\username\AppData\Local\Programs\Python\Python38\lib\subprocess.py", line 1307, in 
_execute_child
    hp, ht, pid, tid = _winapi.CreateProcess(executable, args,
FileNotFoundError: [WinError 2] The system cannot find the file specified
```

**Expected behavior**
I had expected link prediction output, as per https://pykeen.readthedocs.io/en/latest/tutorial/making_predictions.html

**Environment:**
I am running on Windows 10, in PowerShell, with Python 3.8.6 (tags/v3.8.6:db45529, Sep 23 2020, 15:52:53) [MSC v.1927 64 bit (AMD64)], on win32

Running pykeen version resulted in the following error:
```python-traceback
Missing handler in RGCN for activation_cls: type=typing.Union[typing.Type[torch.nn.modules.module.Module], NoneType] default=None
Missing handler in RGCN for activation_kwargs: type=typing.Union[typing.Mapping[str, typing.Any], NoneType] default=None
Unable to handle parameter in RGCN: edge_weighting
Missing handler in SimplE for clamp_score: type=typing.Union[float, typing.Tuple[float, float], 
NoneType] default=None
Traceback (most recent call last):
  File "C:\Users\username\AppData\Local\Programs\Python\Python38\lib\runpy.py", line 194, in _run_module_as_main
    return _run_code(code, main_globals, None,
  File "C:\Users\username\AppData\Local\Programs\Python\Python38\lib\runpy.py", line 87, in _run_code
    exec(code, run_globals)
  File "C:\Users\...\env\Scripts\pykeen.exe\__main__.py", line 7, in <module>
  File "c:\users\...\env\lib\site-packages\click\core.py", line 829, in __call__
    return self.main(*args, **kwargs)
  File "c:\users\...\env\lib\site-packages\click\core.py", line 781, in main
    with self.make_context(prog_name, args, **extra) as ctx:
  File "c:\users\...\env\lib\site-packages\click\core.py", line 700, in make_context
    self.parse_args(ctx, args)
  File "c:\users\...\env\lib\site-packages\click\core.py", line 1212, in parse_args
    rest = Command.parse_args(self, ctx, args)  
  File "c:\users\...\env\lib\site-packages\click\core.py", line 1048, in parse_args
    value, args = param.handle_parse_result(ctx, opts, args)
  File "c:\users\...\env\lib\site-packages\click\core.py", line 1630, in handle_parse_result
    value = invoke_param_callback(self.callback, ctx, self, value)
  File "c:\users\...\env\lib\site-packages\click\core.py", line 123, in invoke_param_callback
    return callback(ctx, param, value)
  File "c:\users\...\env\lib\site-packages\pykeen\cli.py", line 56, in _version_callback
    ('pykeen', get_version(with_git_hash=True)),  File "c:\users\...\env\lib\site-packages\pykeen\version.py", line 44, in get_version
    return f'{VERSION}-{get_git_hash()}' if with_git_hash else VERSION
  File "c:\users\...\env\lib\site-packages\pykeen\version.py", line 26, in get_git_hash
    ret = check_output(  # noqa: S603,S607      
  File "C:\Users\username\AppData\Local\Programs\Python\Python38\lib\subprocess.py", line 411, in check_output
    return run(*popenargs, stdout=PIPE, timeout=timeout, check=True,
  File "C:\Users\username\AppData\Local\Programs\Python\Python38\lib\subprocess.py", line 489, in run
    with Popen(*popenargs, **kwargs) as process:  File "C:\Users\username\AppData\Local\Programs\Python\Python38\lib\subprocess.py", line 854, in __init__
    self._execute_child(args, executable, preexec_fn, close_fds,
  File "C:\Users\username\AppData\Local\Programs\Python\Python38\lib\subprocess.py", line 1307, in 
_execute_child
    hp, ht, pid, tid = _winapi.CreateProcess(executable, args,
FileNotFoundError: [WinError 2] The system cannot find the file specified
```

I would greatly appreciate any advice you have on resolving this issue.
Sincerely,
--Jeffrey Sardina



Hi @Jeffrey-Sardina, it looks like there could be a problem with the way you installed PyKEEN on Windows. While we'd highly suggest using a unix system instead, we've got a tutorial for installation on Windows using Conda here: https://pykeen.readthedocs.io/en/latest/installation.html#windows-users

However, NumPy just released 1.12 recently and we haven't had much experience with its implications. Try the first thing then let's see what happens

Hello @cthoyt 

Thank you for your reply! Changing to an older numpy installation did not seem to help. I ran through those install instructions as well (uninstalling my previous PyKEEN first), and unfortuantely I still got the same error. I see that the Windows build is flagged as experimental however, so I'll see if I can use Linux.

I've had some trouble getting this up an running on the Windows Subsystem for Linux, so I'm going to try running this in a VM (unforunately I do not have easy access to a native linux machine) and see if that works. I'll follow up here once I see how that goes.

I installed PyKEEN via "pip3 install pykeen" on an Ubuntu 18 VM, and then ran the same code as above. Doing so gave me the error:

```
No random seed is specified. Setting to 1797760802.
/home/siothrun/.local/lib/python3.6/site-packages/torch/cuda/__init__.py:52: UserWarning: CUDA initialization: Found no NVIDIA driver on your system. Please check that you have an NVIDIA GPU and installed a driver from http://www.nvidia.com/Download/index.aspx (Triggered internally at  /pytorch/c10/cuda/CUDAFunctions.cpp:100.)
  return torch._C._cuda_getDeviceCount() > 0
No cuda devices were available. The model runs on CPU
Training epochs on cpu: 100%|████████████████████████████████████████████████████████████████████████████████████████| 5/5 [00:00<00:00,  5.26epoch/s, loss=0.00505, prev_loss=0.00535]
INFO:pykeen.evaluation.evaluator:Starting batch_size search for evaluation now...                                                                                                      
INFO:pykeen.evaluation.evaluator:Concluded batch_size search with batch_size=201.
Evaluating on cpu: 100%|█████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 201/201 [00:00<00:00, 19.9ktriple/s]
INFO:pykeen.evaluation.evaluator:Evaluation took 0.01s seconds
TransE(
  (loss): MarginRankingLoss()
  (regularizer): NoRegularizer()
  (entity_embeddings): Embedding(14, 50)
  (relation_embeddings): Embedding(55, 50)
)
Traceback (most recent call last):
  File "triail.py", line 15, in <module>
    predicted_tails_df = model.get_tail_prediction_df('brazil', 'intergovorgs')
  File "/home/siothrun/.local/lib/python3.6/site-packages/torch/nn/modules/module.py", line 779, in __getattr__
    type(self).__name__, name))
torch.nn.modules.module.ModuleAttributeError: 'TransE' object has no attribute 'get_tail_prediction_df'
```

Interestingly, I have been getting this same error on the Windows Subsystem for Linux as well. Any idea what this could be?

@Jeffrey-Sardina ahh you've found a fatal flaw in our documentation - the default one is the latest instead of stable. We just changed the names of those prediction functions (purely cosmetic)

See the old names for the prediction functions at https://pykeen.readthedocs.io/en/stable/tutorial/making_predictions.html. We'll be making a release for PyKEEN 1.2.0 with these changes

@cthoyt wonderful, that is working as expected now. Thank you for your help!