NoRM

开关电源和家电电源常用电磁兼容(EMC)执行标准

自作多情 提交于 2019-12-05 03:59:55
通用电磁兼容标准(EMC Standard)对照表 目的 ,给予电源及相关电行业开发或测试人员参考,查找或引用更加方便。包括 传导 、 辐射 以及 谐波 。 下面对常见的一些标准做一些对应解释,特别是针对在通用开关电源和家电行业的标准,如下是对一些电磁标准的解释。 对欧洲标准,一般是借用国际标准,所以常写为IEC/EN IEC是国际电工委员会,英文全称为:International Electrotechnical Commission;EN是欧洲标准的简称,英文全称为:European Norm。 谐波标准要求: GB17625.1对设备输入电流≤16A 的EMC 谐波 做了规定,对应国际标准IEC61000-3-2 GB 17625.1-2012/IEC 61000-3-2:2009 电磁兼容 限值 谐波电流发射限值(设备每相输入电流≤16A)替代了GB17625.1-2003 <谐波测试及标准> ESD(electrostatic discharge)测试标准要求: GB/T 17626.2代替GB/T 17625.2-2006 对设备抗静电做了规定,对应国际标准为/EC1000-4-2,GB/T 17626.2 -2018/IEC1000-4-2 电磁兼容 试验和测量技术 静电放电抗扰度试验 <ESD测试及标准> EFT(electric fast transient

MongoDB Norm query nested objects

萝らか妹 提交于 2019-12-05 00:51:40
问题 Does anyone have a sample of how to query for nested/inner objects in MongoDB using NORM (C#)? For example, if a typical document in a collection looks like Order/OrderItems, how can I look up a specific OrderItem by OrderItem.Quantity > 10. 回答1: Typing this from memory, so sorry if it's wildly wrong: using ( var session = new MongoSession<Order>( DbName ) ) { var orders = session.Queryable .Where( o => o.OrderItems.Any( oi => oi.Quantity > 10 ) ) .ToList(); } 回答2: You need to create extra

Get norm of numpy sparse matrix rows

China☆狼群 提交于 2019-12-04 23:49:25
问题 I have a sparse matrix that I obtained by using Sklearn's TfidfVectorizer object: vect = TfidfVectorizer(sublinear_tf=True, max_df=0.5, analyzer='word', vocabulary=my_vocab, stop_words='english') tfidf = vect.fit_transform([my_docs]) The sparse matrix is (taking out the numbers for generality): <sparse matrix of type '<type 'numpy.float64'>' with stored elements in Compressed Sparse Row format>] I am trying to get a numeric value for each row to tell me how high a document had the terms I am

Modelling a NoSQL Forum Application with C# / ASP.net MVC

时光毁灭记忆、已成空白 提交于 2019-12-04 13:55:41
问题 I'm currently developing a Forum (Question / Answer) based application. Using C# ASP.net MVC and MongoDB for data storage. I'm currently looking at the model. I was thinking of having separate classes like this: (simplified) public class Question { public string ID { get; set; } public string Title { get; set; } public string Body { get; set; } public List<string> Tags { get; set; } public DateTime DateCreated { get; set; } public string ForumID { get; set; } } Answer public class Answer {

MongoDB design - tags

痞子三分冷 提交于 2019-12-04 12:37:03
问题 I'm new with MongoDB. I have a design question, about performance of MongoDB. Lets say I have the class Movies with two properties, Name and Director. Also I want to tag this Movie Class. Is better to add a new propertie of strings[] to this class, or to create a new class MovieTags? I know I will query this tags a lot because I will use an autocomplete on the UI. For this autocomplete function I only need the tags, not the Movie object . What option is better? add a propertie of strings[] or

When to use Singleton vs Transient vs Request using Ninject and MongoDB

大兔子大兔子 提交于 2019-12-03 19:22:50
问题 I'm not quite sure when I should use SingletonScope() vs TransientScope() vs RequestScope() when I do my binding in my global.cs file. I have for example my call to MongoSession (using NoRM and the mvcStarter project http://mvcstarter.codeplex.com/) which is set to SingletonScope but I created a repository that use this MongoSession object to make calls to Mongo easier, e.g., I have a NewsRepository which uses MongoSession to fetch my News items from the data. As an example I have a call that

MongoDB Norm query nested objects

夙愿已清 提交于 2019-12-03 16:35:19
Does anyone have a sample of how to query for nested/inner objects in MongoDB using NORM (C#)? For example, if a typical document in a collection looks like Order/OrderItems, how can I look up a specific OrderItem by OrderItem.Quantity > 10. Typing this from memory, so sorry if it's wildly wrong: using ( var session = new MongoSession<Order>( DbName ) ) { var orders = session.Queryable .Where( o => o.OrderItems.Any( oi => oi.Quantity > 10 ) ) .ToList(); } You need to create extra field 'size', that you increment when add new items, and query on it. 来源: https://stackoverflow.com/questions

Get norm of numpy sparse matrix rows

ぐ巨炮叔叔 提交于 2019-12-03 15:17:52
I have a sparse matrix that I obtained by using Sklearn's TfidfVectorizer object: vect = TfidfVectorizer(sublinear_tf=True, max_df=0.5, analyzer='word', vocabulary=my_vocab, stop_words='english') tfidf = vect.fit_transform([my_docs]) The sparse matrix is (taking out the numbers for generality): <sparse matrix of type '<type 'numpy.float64'>' with stored elements in Compressed Sparse Row format>] I am trying to get a numeric value for each row to tell me how high a document had the terms I am looking for. I don't really care about which words it contained, I just want to know how many it

Modelling a NoSQL Forum Application with C# / ASP.net MVC

萝らか妹 提交于 2019-12-03 09:45:00
I'm currently developing a Forum (Question / Answer) based application. Using C# ASP.net MVC and MongoDB for data storage. I'm currently looking at the model. I was thinking of having separate classes like this: (simplified) public class Question { public string ID { get; set; } public string Title { get; set; } public string Body { get; set; } public List<string> Tags { get; set; } public DateTime DateCreated { get; set; } public string ForumID { get; set; } } Answer public class Answer { public string ID { get; set; } public string QuestionID { get; set; } public string Body { get; set; }

Using numba for cosine similarity between a vector and rows in a matix

匿名 (未验证) 提交于 2019-12-03 09:14:57
可以将文章内容翻译成中文,广告屏蔽插件可能会导致该功能失效(如失效,请关闭广告屏蔽插件后再试): 问题: Found this gist using numba for fast computation of cosine similarity. import numba @numba.jit(target='cpu', nopython=True) def fast_cosine(u, v): m = u.shape[0] udotv = 0 u_norm = 0 v_norm = 0 for i in range(m): if (np.isnan(u[i])) or (np.isnan(v[i])): continue udotv += u[i] * v[i] u_norm += u[i] * u[i] v_norm += v[i] * v[i] u_norm = np.sqrt(u_norm) v_norm = np.sqrt(v_norm) if (u_norm == 0) or (v_norm == 0): ratio = 1.0 else: ratio = udotv / (u_norm * v_norm) return ratio Results look promising (500ns vs. only 200us without jit decorator in