如何将大型十六进制值用作培训数据?在机器学习中
我正在考虑使用 sklearn 进行机器学习。但我拥有的训练数据是一个很大的十六进制值。我如何将其处理为训练数据?下面的代码是一个十六进制值的示例
import sklearn
hex_train=''
我拥有的所有训练数据都是这些值。我不知道如何预处理这些值并将其用作训练数据。我所知道的是,我应该将这些值转换为 float
类型吗?
I am thinking of doing machine learning using sklearn
. But the training data I have is a large hexadecimal value. How do I process this into training data? The code below is an example of a hexadecimal value
import sklearn
hex_train='0x504F1728378126389BACDDDDDFF12873788912893788265722F75706C6F61642F7068702F75706C6F61642E7068703F547970653D4D6564696120485454502FAABBD10D0A436F6E74656E742D547970653A206D756C7469706172742F666F726D2D646174613B20436861727365743D5554462D383B20626F756E646172793D5430504861636B5465616D5F5745424675636B0AD0557365722D4167656E743A205765624675636B205430504861636B5465616D207777772E7430702E78797A200D0A526566657265723A206874747012334BDBFABFBDBF123FBDFBE74656E742D4C656E6774683A203234370D0A4163636570743A202A2F2A0D0A486F73743A206F6365616E2E6B697374691636B5465616D5F5745424675636B0D0A436F6E74656E742D446973706F736974696F6E3A20666F726D2D646174613B206E616D653D224E657746696C65223B2066696C656E616D653D224C75616E2E747874220D0A436F6E74656E742D547970653A20696D6165672F6A7065670D0A0D0A3C3F7068700D0A40707265675F7265706C61636528222F5B706167656572726F725D2F65222C245F504F53545B27446176F756E6427293B0D0A3F3E0D0A2D2D5430504861636B5465616D5F5745424675636B2D2D0D0A'
All the training data I have are these values. I don't know how to preprocess these values and use them as training data. What I know is that should I convert these values into float
types?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
这是将十六进制转换为十进制的功能!
Here is a function to convert hex to decimal !