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

Issue compiling from source #178

Closed
dandantsui opened this issue May 12, 2021 · 10 comments
Closed

Issue compiling from source #178

dandantsui opened this issue May 12, 2021 · 10 comments
Labels

Comments

@dandantsui
Copy link

dandantsui commented May 12, 2021

Hi there,

I have to first admit I am not familiar with Visual Studio. I keep running into flext-max_s.lib issues and also unable to compile a x64 version of flext and also "struct alignment must be set to default"

Is there someone who can upload a built Max externals from the current source? I am unable to write the model to the file and need the fixed code. If you could also change the build version so when the external is loaded, Max prints to the console a different version!

Any help is greatly appreciated!

@batchku
Copy link
Contributor

batchku commented May 12, 2021 via email

@dandantsui
Copy link
Author

dandantsui commented May 12, 2021

@batchku I do use the one from the package manager, however it still has the bug from issue #171 which I need fixed. I need to have the ability to write and read saved data/model.

I see that a PR is merged to #176 and indeed the behaviour is fixed when compiling with Xcode. I just need Windows prebuilt files if someone can compile them.

@dandantsui
Copy link
Author

dandantsui commented May 12, 2021

@NiccoloGranieri @batchku I have successfully compiled the RELEASE x64 Max external for Windows. I can confirm WRITE function works but now the READ and CLEAR function crashes Max as soon as I read a SECOND file.

When I comment out mlBase.clear() function in ml_ml.cpp and compile, clear function works fine. I think there is something wrong with mlBase.clear and mlBase.loadModelFromFile()? I also tried mlBase.load() to no avail.

Can you please advise?? This behavior does not exist on Mac and does not crash Max.

@dandantsui
Copy link
Author

I have found that if I try to use a bpatcher and remove the bpatcher after loading a preset, Max also crashes.
The same behavior exists when after loading a preset and removing the ml.svm object.

There is something truly wrong in ml.lib or the GRT package.

@NiccoloGranieri
Copy link
Contributor

Hi @dandantsui, thanks for the insightful feedback and bug reporting. @jamiebullock and I will try our best to replicate the bugs mentioned above and do a new build this weekend. Unfortunately we've both become increasingly busy in the past 6 months and it is hard to keep up with ml.lib's needs. However, considering that the (write) bug has been already fixed and merged from a PR, we feel like it's important to address these other issues you found and do a new bug-fixing release.

We will keep you posted as soon as we have something.

@dandantsui
Copy link
Author

Thanks for the response!

@NiccoloGranieri more updates... discovered that GRT is not at fault. When loading a .data file, I can load as many times as I want. As soon as I try to read the .model file a second time, it crashes. I believe the .model file is written by ml.svm.

Can you please confirm?

@NiccoloGranieri
Copy link
Contributor

Hi @dandantsui, ml.lib 1.1.3 can be now found on the Max Package Manager. I personally tested the build both on macOS and on Windows and can assure you none of the (read), (write) or (clear) bugs are present.

@dandantsui
Copy link
Author

@NiccoloGranieri thanks for pushing the new files. I appreciate the help with this!

I just tested this behavior on Windows again and it seems like the same issues are present. It might help if I provide you .data and .model files? I just made these files with the newest ml.lib 1.1.3

Could you please try doing this? (read) new.data & new.model, then after (read) new2.data & new2.model. As soon as I try to (read) new2.model it crashes. If I (read) new.data & new.model then press (clear) it also crashes.

Crash ONLY happens when I read a SECOND dataset, or (clear) from the first dataset.

I've tried loading the files in two different ways. (both result in crash)
read "C:/Users/User/Desktop/new.data"
read "C:/Users/User/Desktop/new.model"

and also
read "C:/Users/User/Desktop/new"

Am I doing anything wrong??

ml_svm_2_datasets.zip

@jamiebullock
Copy link
Contributor

Hi @dandantsui

I have now investigated this, and unfortunately, the problem is occurring due to an upstream bug in GRT. I have reported the issue here. However, I note that there has been no activity on that project for 2 years.

My recommendation would be that you either restart Max between loading models, or use an alternative classifier such as ml.ann.

@dandantsui
Copy link
Author

Thankks @jamiebullock for your time. I really appreciate it.

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

No branches or pull requests

4 participants