open-ephys-GUI-binaries / open-ephys

Compiled binaries for Open Ephys GUI (https://github.com/open-ephys/plugin-GUI)
6 stars 8 forks source link

Installing plugins on Neuropixels version of OE #9

Open DavidRuhl opened 4 years ago

DavidRuhl commented 4 years ago

Hi,

We are moving data collection from 32 channel probes to a Neuropixels setup, and so I am switching to the Neuropixels version of Open Ephys. How can I install plugins to this new version? We use Crossing Detector (https://github.com/tne-lab/crossing-detector) in our current (non-Neuropixels) OE version, but I cannot figure out how to add plugins to the new OE version (no plugins.sln file).

Thank you for your advice (and more broadly for the nifty software!).

Best, David Ruhl UCSD

aacuevas commented 4 years ago

Hello,

We have changed the way plugins are compiled for the GUI, so there is no need for a plugins.sln file. Tou can find information on the new process in our wiki. The crossing detector plugin is already adapted to this new workflow and includes updated build instructions on their readme file.

Best, Aarón

DavidRuhl commented 4 years ago

Hi Aaron,

Thank you! I am confused though: those docs say "Before building a plugin, the build files for the base GUI must have been created by running cmake for it, as the process creates some files needed by the plugins." But the Neuropixels version of OE (https://github.com/open-ephys-GUI-binaries/open-ephys/tree/neuropix) does not have either a CMakeLists.txt nor a Build subdirectory, so how can I generate the build files as described here? https://open-ephys.atlassian.net/wiki/spaces/OEW/pages/1301643269/Creating+Build+files

Best, David

DavidRuhl commented 4 years ago

Hi. Sorry, is there a different forum in which I should have posted this thread? If so please pardon me! I still do not understand how one could use cmake to add a plugin like crossing detector to the Neuropixels version of OE. Per your wiki, the GUI build files must be generated before the plugin build files, but there is no CMakeLists file for the Neuropixels OE version (https://github.com/open-ephys/plugin-GUI/tree/neuropixels), so I can't generate them as the wiki instructs. I'm sure there must be something obvious I'm missing, yes? Thank you, any thoughts appreciated! David

medengineer commented 4 years ago

Hi David,

The neuropixels version of the GUI binaries is now just the master version of the GUI compiled + neuropixels relevant plugins compiled separately and pre-installed. To install the CrossingDetector, you only need to build against the master branch of the plugin-GUI for it to be compatible with the neuropix version of the binaries.

Pavel

DavidRuhl commented 4 years ago

Hi Pavel, Great, thank you for the info! I have a followup though: after installing CrossingDetector as instructed, the Neuropixels version of OE no longer opens, instead giving the error: <<The program can't start because VCRUNTIME140_1.dll is missing from your computer. Try reinstalling the program to fix this problem.>>

Your github page links to a page for the Visual C++ Redistributable Package Package that we should install in the case of missing dll errors, but that did not change things. Nor did repairing/reinstalling either the Redistributable Package, Visual Studio 2013, or Neuropixels OE. Running a system restore to a point before CrossingDetector was installed doesn't help either.

Any ideas how to fix this and get the Neuropixels OE running again? Other versions of OE still open and run fine, so it's a dll needed specficially by the Neuropixels version that got deleted or corrupted in the course of installing CrossingDetector.

Thank you!

jsiegle commented 4 years ago

VCRUNTIME140 refers to Visual Studio 2015, so you'll need to download and install these: https://www.microsoft.com/en-us/download/details.aspx?id=48145

@medengineer and @anjaldoshi, is there a way to statically link these runtime files, so users don't need to install them separately?

DavidRuhl commented 4 years ago

Hmm, installing those didn't seem to help - still the same error RE VCRUNTIME140_1.dll being missing, and OE doesn't open... Other options I could try?

medengineer commented 4 years ago

A user with the same exact issue uninstalled and re-installed all Visual C++ packages with success.

DavidRuhl commented 4 years ago

No luck - had tried this earlier, and just tried again, didn't resolve the issue. Which versions of Visual C++ specifically? I installed the two jsiegle linked above, and two of the three linked under "Visual C++..." here https://github.com/open-ephys-GUI-binaries/open-ephys/tree/neuropix (The third, vcredist_arm , gives a "not a valid Win32 application" when opened)...

medengineer commented 4 years ago

Couple more things to try. We've updated to VS2019 so the best Visual C++ packages to have installed are here: https://support.microsoft.com/en-gb/help/2977003/the-latest-supported-visual-c-downloads. We've also seen issues related to older versions of CMake so you can also try making sure your CMake version is 3.15 or higher. I will update the neuropix docs to reflect this.

DavidRuhl commented 4 years ago

Great, thanks! That fixed the VCRUNTIME_140_1.dll error, and I can open Neuropixels version of OE again. (It was the VS2019 installation that did it, I had had the up-to-date CMake.)

Now, RE running Crossing Detector in the Neuropixels OE version: I've build the plugin against the master version of the plugin-GUI binaries as you suggested, and it opens/runs fine in that (non-Neuropixels) OE version. How can I now run Crossing Detector from within the Neuropixels OE version?
Just moving "CrossingDetector" to the matching sister directory on the Neuropixels version (with or without copying CrossingDetector.dll to the "plugins" subfolder) didn't do it. And building the "INSTALL" solution in "OE_PLUGIN_CrossingDetector.sln" with generated a very long list of errors. So what is the last step to run the compiled Crossing Detector in the Neuropixels OE?

I am very much appreciating your help on this!! Best, David

open-ephys-plugins commented 4 years ago

Awesome, so if you're able to use the CrossingDetector plugin in the master version of the plugin-GUI, you should only need to copy the CrossingDetector.dll file from the master version's plugins directory to the Neuropixels OE plugins directory. No need to move any CrossingDetector folders or build any .sln files. If you did copy the CrossingDetector.dll into the Neuropixels OE plugins directory, are you seeing any error in the console regarding loading the plugin when launching the GUI?

DavidRuhl commented 4 years ago

Hi! So I had copied CrossingDetector.dll from C:\OpenEphysMasterCMake\plugin-GUI\Build\Release\plugins to the plugins director of the Neuropixels version, but the plugin does not appear when I open the Neuropixels OE version.

Yes, there is an error in the debug console when I open the Neuropixels OE version, it reads: << Loading Plugin: CrossingDetector... C:\Users\pavel.kulik\Projects\OpenEphys\plugin-Gui\Source\Processors\PluginManager\PluginManager.cpp:181: Failed to load plugin DLL: DLL Error 0xc1

I gather this is pointing to a file that it shouldn't?

Thanks! David

open-ephys-plugins commented 4 years ago

Can you confirm you built the Release version of both the master plugin-GUI and CrossingDetector? It's likely the CrossingDetector works with master because they were both built under Debug configuration and OE Neuropixels is a Release configuration.

DavidRuhl commented 4 years ago

Yes they were both build as release versions.

(I confirmed this for the plugin by checking that C:\OpenEphysMasterCMake\CrossingDetector\CrossingDetector\Build\Release had files while C:\OpenEphysMasterCMake\CrossingDetector\CrossingDetector\Build\Debug was empty, and the non-Neuropixels gui is in C:\OpenEphysMasterCMake\plugin-GUI\Build\Release If there's some other way I should confirm pls let me know)

open-ephys-plugins commented 4 years ago

Hi David, When you run the OE Neuropixels binaries are you able to see the StreamMuxer and ProbeViewer plugins in the Processors List on the left?

DavidRuhl commented 4 years ago

Yes, both appear and can be inserted into signal streams.

open-ephys-plugins commented 4 years ago

Can you shoot me an email at pavel@open-ephys.org and we can continue from there?