Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

H5f threw exception #313

Open
Marco-Pellegrino opened this issue Jul 18, 2023 · 7 comments
Open

H5f threw exception #313

Marco-Pellegrino opened this issue Jul 18, 2023 · 7 comments

Comments

@Marco-Pellegrino
Copy link

Hi @LiorBanai !

I am facing an issue while trying to run the code on my M2 machine.

Does it suppose to work? Any tip?

Screenshot 2023-07-18 at 19 57 04 Screenshot 2023-07-17 at 00 04 41

recorder.mpco.zip

@LiorBanai
Copy link
Owner

Hi @Marco-Pellegrino
looking at the HDF.PInvoke supported frameworks it should work https://www.nuget.org/packages/HDF.PInvoke.1.10/
are you compiling it in AnyCPU or x64/32. Since it is native AnyCPU won't work..

@LiorBanai
Copy link
Owner

Can you run any of the unit tests in x64 and see if they work?

@Marco-Pellegrino
Copy link
Author

it looks like that I will need to struggle a little bit :)
Not sure I have the expertise to solve the issue but I will try.

I will keep you posted

@Marco-Pellegrino
Copy link
Author

Interestin fact.

PureHDF run without any problem

@LiorBanai
Copy link
Owner

PureHDF has no dependency on Pinvoke C++. If you only need reading then PureHDF is the library to go with :)

@Marco-Pellegrino
Copy link
Author

Yes.
I only need to read the data.

Looks like that I will need to learn a little bit PureHDF and convert some of my previous code.

Thanks a lot @LiorBanai :)

@Sahasrara
Copy link

Sahasrara commented Jun 6, 2024

I'm having the same issue. I'm trying to use Tensorflow.NET in Unity and getting this error:

DllNotFoundException: hdf5 assembly:<unknown assembly> type:<unknown type> member:(null)
HDF.PInvoke.H5F..cctor () (at /home/appveyor/projects/hdf-pinvoke-1-10/submodules/HDF.PInvoke/HDF5/H5Fpublic.cs:41)
Rethrow as TypeInitializationException: The type initializer for 'HDF.PInvoke.H5F' threw an exception.
HDF5CSharp.Hdf5.OpenFile (System.String filename, System.Boolean readOnly, System.Boolean attemptShortPath) (at <a573135056b64eceaab6f7dd4003494c>:0)
Tensorflow.Keras.Engine.Model.load_weights (System.String filepath, System.Boolean by_name, System.Boolean skip_mismatch, System.Object options) (at <3504e8007fee496baf2c8fdd9578867a>:0)
Slay.Crepe.BuildAndLoadModel (Slay.Crepe+ModelCapacity capacity) (at Assets/Scripts/Sound/AI/Crepe.cs:78)
Slay.Crepe.Start () (at Assets/Scripts/Sound/AI/Crepe.cs:13)

Any idea what I might be doing wrong? Here's what NugetForUnity pulled in:

<?xml version="1.0" encoding="utf-8"?>
<packages>
  <package id="Fody" version="6.7.0" />
  <package id="Google.Protobuf" version="3.21.12" />
  <package id="HDF.PInvoke.1.10" version="1.10.612" />
  <package id="HDF5-CSharp" version="1.19.0" />
  <package id="MethodBoundaryAspect.Fody" version="2.0.149" />
  <package id="Microsoft.Build.Framework" version="17.10.4" />
  <package id="Microsoft.Build.Utilities.Core" version="17.10.4" manuallyInstalled="true" />
  <package id="Microsoft.IO.Redist" version="6.0.0" manuallyInstalled="true" />
  <package id="Microsoft.NET.StringTools" version="17.10.4" />
  <package id="Microsoft.Win32.Registry" version="5.0.0" />
  <package id="Newtonsoft.Json" version="13.0.3" />
  <package id="OneOf" version="3.0.263" />
  <package id="Protobuf.Text" version="0.7.2" />
  <package id="PureHDF" version="1.0.0-beta.2" />
  <package id="Razorvine.Pickle" version="1.4.0" />
  <package id="Serilog" version="2.10.0" />
  <package id="Serilog.Sinks.Console" version="4.1.0" />
  <package id="SharpZipLib" version="1.4.2" />
  <package id="System.Collections.Immutable" version="8.0.0" />
  <package id="System.Configuration.ConfigurationManager" version="8.0.0" />
  <package id="System.Resources.Extensions" version="7.0.0" />
  <package id="System.Runtime.CompilerServices.Unsafe" version="6.0.0" />
  <package id="System.Security.AccessControl" version="6.0.0" />
  <package id="System.Security.Cryptography.ProtectedData" version="8.0.0" />
  <package id="System.Security.Permissions" version="8.0.0" manuallyInstalled="true" />
  <package id="System.Security.Principal.Windows" version="5.0.0" />
  <package id="System.Text.Encoding.CodePages" version="7.0.0" />
  <package id="TensorFlow.Keras" version="0.15.0" manuallyInstalled="true" />
  <package id="TensorFlow.NET" version="0.150.0" manuallyInstalled="true" />
</packages>

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants