feat: add one-hot data preprocessing#46
Merged
Yanyan-Wang merged 1 commit intomasterfrom Dec 30, 2021
Merged
Conversation
77da8ad to
6f091eb
Compare
Yanyan-Wang
reviewed
Dec 29, 2021
| dataList.forEach(data => { | ||
| keys = keys.concat(Object.keys(data)); | ||
| }) | ||
| keys = Array.from(new Set(keys)); |
Contributor
There was a problem hiding this comment.
| } | ||
| }) | ||
| if (value.length) { | ||
| allKeyValueMap[key] = Array.from(new Set(value)); |
| allKeyValueMap[key] = Array.from(new Set(value)); | ||
| } | ||
| }) | ||
| delete allKeyValueMap['id']; |
Contributor
There was a problem hiding this comment.
有没有可能让用户传入一些字段名字,用来排除计算。或者说传入一些字段名字,用于计算相似性
Member
Author
There was a problem hiding this comment.
好建议,已经加上extractKeys和noExtractKeys,用于指定仅计算哪些属性或排除计算哪些属性
73ba18a to
741c5f9
Compare
chore: perf code chore: perf code chore: perf code feat: 数据预处理支持指定要抽取的keys和不抽取的keys chore: perf code chore: perf code
a0c3bfb to
0096424
Compare
Yanyan-Wang
approved these changes
Dec 30, 2021
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
用于i-louvain、nodes-cosine-similarity等算法的节点属性特征向量提取
之前只抽取了数值型和日期型的属性做运算
one-hot可以处理所有离散型的数据提取映射成特征向量